Page 1 of 1

Mass rename question

Posted: 2020 Apr 20, 10:46
by sallybelgium
What I would like to do with the mass rename tool is to rename filenames completely to captial letters.
For exemple Testfile.txt ==> TESTFILE.TXT

How should I do this?

Re: Mass rename question

Posted: 2020 Apr 20, 12:30
by nikos
I don't think you can do that... perhaps some of the regular expression gurus in the forum will have another idea?

Re: Mass rename question

Posted: 2020 Apr 20, 18:01
by CrossX
MassRename (a free project by Stulle) can do that (capitalize) and a lot of other things
https://sourceforge.net/projects/mass-rename/

It would be good if Nikos could "embed it" in xplorer2.

Re: Mass rename question

Posted: 2020 Apr 21, 07:09
by sallybelgium
CrossX wrote: 2020 Apr 20, 18:01 MassRename (a free project by Stulle) can do that (capitalize) and a lot of other things
https://sourceforge.net/projects/mass-rename/

It would be good if Nikos could "embed it" in xplorer2.
The thing is, that I bought xplorer to have all those tools at hand...
On my mac I have pathfinder installed, and that rename tool can do it easily..I thought that maybe it could be done in xplorer² as well...

Re: Mass rename question

Posted: 2020 Apr 23, 07:20
by FrizzleFry
nikos wrote: 2020 Apr 20, 12:30 I don't think you can do that... perhaps some of the regular expression gurus in the forum will have another idea?
Regex does support case conversions with the \U \L \F \I commands but these do not seem to be supported in the x2 regex.
What regex implementation is x2 using?

Re: Mass rename question

Posted: 2020 Apr 23, 08:51
by nikos

Re: Mass rename question

Posted: 2020 Apr 23, 11:36
by longfellow
FrizzleFry wrote: 2020 Apr 23, 07:20 Regex does support case conversions with the \U \L \F \I commands but these do not seem to be supported in the x2 regex.
Yeah, this is standard Regex, and while these commands are implemented in the Deelx engine, they don't actually work. We tried to troubleshoot this last November, you can read about it here, if so inclined:

viewtopic.php?f=18&t=11784

So sadly, case conversion is off the table until this is resolved :(

Re: Mass rename question

Posted: 2020 Apr 24, 17:53
by FrizzleFry
So x2's Mass Rename cannot do case conversions but uppercasing filenames is a fairly easy rename to implement. A simple way is to use a vbscript and assign it to a user command...

create a vbscript file (just a text file with a vbs extension)

Code: Select all

Set WshShell = WScript.CreateObject("WScript.Shell")

if WScript.Arguments.Count = 0 then
	WScript.Echo "No file(s) to rename specified."
	WScript.Quit
end if

Set FSO = CreateObject("Scripting.FileSystemObject")

Sub RenameUpperCase(filename)
	Dim file, name
	Set file = FSO.GetFile(filename)
	name = file.Name
	file.Move UCase(name)
End Sub

For Each file In WScript.Arguments
	If (FSO.FileExists(file)) Then RenameUpperCase file
Next

WshShell.SendKeys "^r"

Set FSO = Nothing
set WshShell = Nothing
then create a user command like

>wscript D:\scripts\VBScript\renuc.vbs $S

change 'D:\scripts\VBScript\renuc.vbs' to the full path of the vbscript file you created

you can even add the user command as a button on a toolbar to make it more convenient to use... just select the files to rename then click the user command button (or run it from the menu)...

Re: Mass rename question

Posted: 2020 Apr 24, 20:14
by pj
AWXRENAME hasn't been updated for years but still works for me. A simple rt-click interface with options for LC, UC, Mixed (Title) and custom and PERL script selections, will operate on all selected files in the open folder.

http://www.arniworld.de/downloads.htm

Re: Mass rename question

Posted: 2020 Apr 25, 05:42
by FrizzleFry
Yeah. I use awxRename also. Problem is that the file you download from the arniWORLD site now is a passworded archive.