Posting new Threads / Batch Files
It has been a long time since I used this site. I had a hard time finding where to make a new post, even though I had done it previously.
My situation is that I want to pass a paremeter in my batch file. The file is rather simple.
IF %1 = "3" XCOPY w:/*.* C:\OLDDOCS\ /S/V/Y/D
cd c:\Billing\Progs
vfp9.exe Main.Prg
I only want to execute the "XCOPY" command when the parameter is "3".
What happens is that when the parameter is "3", the "XCOPY" command will execute, but none of the commands that follow it.
If the parameter is not "3", then nothing executes.
If I remove "IF %1 = "3" ", then every thing executes.
Help
It has been a long time since I used this site. I had a hard time finding where to make a new post, even though I had done it previously.
My situation is that I want to pass a paremeter in my batch file. The file is rather simple.
IF %1 = "3" XCOPY w:/*.* C:\OLDDOCS\ /S/V/Y/D
cd c:\Billing\Progs
vfp9.exe Main.Prg
I only want to execute the "XCOPY" command when the parameter is "3".
What happens is that when the parameter is "3", the "XCOPY" command will execute, but none of the commands that follow it.
If the parameter is not "3", then nothing executes.
If I remove "IF %1 = "3" ", then every thing executes.
Help