year in file name & last modified date

Ask your Windows PowerShell-related questions, including questions on cmdlet development!
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
Locked
User avatar
sshree43
Posts: 33
Joined: Wed Jun 27, 2018 11:57 am

year in file name & last modified date

Post by sshree43 » Fri Jun 29, 2018 8:37 am

Hi Expert,



I wanted to move item based on 'year' in the file name and last modified date in the file name

the below example year=2017 and last modified date 28/06/2017 22:00 so the remaining file will go into the archive

similarly, for the year 2017 so in the result, only 2 files will be there and remaining files will go to the archive



abc_2017.xlsx last modified date 28/06/2017 22:00

abc_2017.xlsx last modified date 27/06/2017 22:00

abc_2017.xlsx last modified date 23/06/2017 22:00

abc_2018 last modified date 28/06/2018 22:00

abc_2018 last modified date 24/06/2018 22:00

abc_2018 last modified date 23/06/2018 22:00





thanks

cody m

Re: year in file name & last modified date

Post by cody m » Mon Jul 02, 2018 8:12 am

[THREAD LOCKED BY MODERATOR]
It looks as though you have posted about this topic in this thread viewtopic.php?f=18&t=12712&p=68433#p68433 . Please refrain from making multiple posts about the same topic.

Locked