I have a lot of files named like
Files_01(some text).png Files_02(some different text).png Files_03(some other text).png Files_04(totally different text).png
What I'm looking for is a way to remove everything in the brackets so that I'm left with:
Files_01.png Files_02.png etc.
I tried the following, but it didn't remove the text in parentheses:
Get-ChildItem .png | foreach {
Rename-Item $_ $_.Name.Replace("()", "")
}