Re: [PCWorks] How to create a batch file to rename a file, then rename it back?

  • From: "Clint Hamilton-PCWorks Admin" <PCWorks@xxxxxxxxxxxxxxxxxxxxxxxx>
  • To: <pcworks@xxxxxxxxxxxxx>
  • Date: Thu, 24 Jul 2008 02:53:35 -0500

I got it working Hugh thanks, I had to remove the second path. 
I don't know why it didn't work the first time.

ren E:\Backups\test.txt test1.txt

-Clint


----- Original Message ----- 



> You have to save it as a .bat file in order for it to work.

Yeah Hugh....that much I know.  ;-)  LOL.

Strange it works for you.  At the command line I get: "The
syntax of the command is incorrect.".  Are you on XP?  You
don't need any of those "echo" lines in it or @ or nothing
else, just **exactly** as you put it?
-Clint

God Bless
Clint Hamilton, Owner
http://www.OrpheusComputing.com
http://www.ComputersCustomBuilt.com


----- Original Message ----- 
From: "Hugh Vandervoort"

You have to save it as a .bat file in order for it to work.
It works perfectly just as it is for me.
If you write it the way you did at the command line, it will
also work,
as long as the path is correct.
The .bat file should show as a DOS Batch file with the special
Batch
file icon.


Clint Hamilton-PCWorks Admin wrote:
> Thanks Hugh, but that's not working, I though it looked a bit
> too simple. I tried on a test file, just as you put it:
>
> ren E:\Backups\test.txt test1.txt
>
> Even tried this with the full paths of both:
>
> ren E:\Backups\test.txt E:\Backups\test1.txt
>
> I click them and nothing happens.

=========================
The list's FAQ's can be seen by sending an email to 
PCWorks-request@xxxxxxxxxxxxx with FAQ in the subject line.

To unsubscribe, subscribe, set Digest or Vacation to on or off, go to 
//www.freelists.org/list/pcworks .  You can also send an email to 
PCWorks-request@xxxxxxxxxxxxx with Unsubscribe in the subject line.  Your 
member list settings can be found at 
//www.freelists.org/cgi-bin/lsg2.cgi/l=pcworks .  Once logged in, you have 
access to numerous other email options.  

The list archives are located at //www.freelists.org/archives/pcworks/ .  
All email posted to the list will be placed there in the event anyone needs to 
look for previous posts.
-zxdjhu-

Other related posts: