Command Prompt REPLACE?

Joined
Dec 18, 2009
Messages
1
Reaction score
0
How do I use the COPY command?

Hi guys. I'm trying to make a batch file which will replaces files in another directory.

There already is the REPLACE command, but you need to specify both sources rather than just the destination.

The only idea that I can come up with is to COPY the files to %windir%/system32 first, then REPLACE the files that I want.. but I am trying to avoid having a middle step.

@ECHO off
ECHO Replacing File...

REPLACE C:\log.txt "C:\Program Files\SysLog\"

ECHO Done
PAUSE
 
Last edited:

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top