Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Change the -Include file extension to whatever you need.
- # This example uses .jpg
- # To ignore file extensions, use this syntax on the first line:
- # Get-ChildItem -Path c:\path\to\source\folder\* |
- Get-ChildItem -Path c:\path\to\source\folder\* -Include *.jpg |
- Sort-Object CreationTime |
- Select-Object -First 1 |
- Move-Item -Destination c:\path\to\destination\folder
Advertisement
Add Comment
Please, Sign In to add comment