Powershell Rename when size was at 1Gb with time stamp

19 views
Skip to first unread message

vignesh k.s

unread,
Feb 27, 2017, 1:15:40 AM2/27/17
to
I have found the script for that but the issue was, it replaces the original file name to time stamp. But instead i want the original file name and time stamp.

Code was :
Get-ChildItem -Path F:\ *.mp4 -Recurse | Where-Object {$_.length/1MB -gt 999} |Rename-Item -newname {$_.LastWriteTime.toString("dd-MM-yyyy-HH.mm") + $_.Extension}
Reply all
Reply to author
Forward
0 new messages