Powershell: Change filename abcd-123.pdf to 123-abcd.pdf


i have folder 1000 files named in format: abcd-123.pdf. allow these files organized correctly according 3-digit number (ie. "123"), have change filenames format 123-abcd.pdf.

i've never used powershell before searching online answer question last friday. appreciate sort of advice or guidance either set me in right direction or tell me answer. cheers! thank you!

i'm also a bit puzzled works without losing extension.  seems to.  here's output:

what if: performing operation "rename file" on target "item: c:\scripts\abcd-123.pdf destination: c:\scripts\123-abcd.pdf".

what's up?

grant ward, a.k.a. bigteddy




Windows Server  >  Windows PowerShell



Comments

Popular posts from this blog

Round Robin is killing performance on our network

WMI Repository 4GB limit - Win 2003 Ent Question

Change home folder default permission?