Here is my code snippet:
Let>MF_RENAME=1
Let>file1=c:\Temp\*.ltr
Let>file2=c:\Temp\*.doc
MoveFile>%file1%,%file2%
I have several hundred files with the ltr extension in c:\temp. I want to rename them with a doc extension.
It does not seem to work as I thought it might.
If I specifically name a file like c:\temp\abc.ltr then it gets renamed to abc.doc
Am I doing something wrong?
Problems with the MoveFile Command??
Moderators: Dorian (MJT support), JRL
-
- Automation Wizard
- Posts: 1101
- Joined: Fri Jan 07, 2005 5:55 pm
- Location: Somewhere else on the planet
It does say in the help that wildcards can be used, but windows is very picky about where you can use them in renaming.
This should work for you, note that it is necessary to first change to the working directory:
Change Directory>c:\temp
RunProgram>cmd /c "rename *.ltr *.doc"
Be sure to make a backup before attempting any global change like this.
This should work for you, note that it is necessary to first change to the working directory:
Change Directory>c:\temp
RunProgram>cmd /c "rename *.ltr *.doc"
Be sure to make a backup before attempting any global change like this.