Question

Locked

Batch file for adding string to filename

By psytrooper ·
Ill get straight into it, I have a file name that get written out every night in the form of
filename April 16, 2012.log

Now i need to rename it to filename April 16, 2012_edit.log daily.
Which is proving to be rather difficult as it appends the _edit after the extention when I run it.

Any help please...

This conversation is currently closed to new comments.

7 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Answers

Collapse -

Deleted

by Slayer_ In reply to Batch file for adding str ...

Deleted cause it was a dbl post

Collapse -

I'm not very good with batch files but

by Slayer_ In reply to Batch file for adding str ...

Is using a VBScript or shelling to another program out of the question?

Collapse -

batch file only

by psytrooper In reply to Batch file for adding str ...

It has to be a batch file unfortunately

Collapse -

Isn't it something like

by Slayer_ In reply to Batch file for adding str ...

Rename *.* *_Edit.*

Collapse -

download this free app

by cd In reply to Batch file for adding str ...
Collapse -

rename file

by cd In reply to Batch file for adding str ...

ren *.log *._edit.log

Collapse -

Try this in a batch file

by dmritchie2 In reply to Batch file for adding str ...

@echo off
copy *.log *.
erase *.log
ren *. *_Edit.log

Back to Software Forum
7 total posts (Page 1 of 1)  

Related Discussions

Related Forums