You're correct - I misread the request. To atone for my sins,
1) download and install the free ActivePerl :
http://downloads.activestate.com/ActivePerl/Windows/5.8/ActivePerl-5.8.8.819-MSWin32-x64-267479.msi2) Copy and paste the following script to a text file:
------- cut -----------
if ($#ARGV <= 0) {
$mydir = ".";
} else {
$mydir = $ARGV[0];
}
print "Rename files in directory $mydir (y/n) ?\n";
$answer = <STDIN>;
chomp $answer;
exit if ($answer =~ /^[nN]/);
print "Renaming files from directory: $mydir\n";
opendir(THISDIR, $mydir) or die "Can't open directory $mydir: $!";
@allfiles = grep { $_ ne '.' and $_ ne '..' and $_ ne "rename.pl"} readdir THISDIR;
closedir THISDIR;
foreach (@allfiles) {
my $save = $_;
if (-e $save) {
s/([A-Z])([a-z]*)/$1$2 /g;
s/ (\..*)?$/$1/;
print "Renaming \"$save\" to \"$_\"\n";
rename "$save", "$_";
}
}
print "Enter to exit\n";
$answer = <STDIN>;
------- cut -----------
3) Rename the text file to "rename.pl" and place this into your folder with the files you want to rename.
4) Double click the file to rename all the files in the directory as per your request.
Do this on a copy of a couple of files first to be sure its what you want. There is no undo!