1.

Solve : How to stop the execution of group of batch files when an if condition failed?

Answer»

I have a 6 batch files(sample1.bat, sample2.bat, sample3.bat, sample4.bat, sample5.bat, sample6.bat) which will be EXECUTED one after the other. I have an if condition in the 3rd batch file(sample3.bat).

If this IF condition failed I want to block the execution of remaining batch files (sample4.bat, sample5.bat, sample6.bat)

Please help.. THANKS in advanceWell. If the batch files are executing the next one then just do this:

If something equ something (your commands) ELSE (exit)Quote from: simhadri1985 on August 25, 2009, 04:15:34 AM

I have a 6 batch files(sample1.bat, sample2.bat, sample3.bat, sample4.bat, sample5.bat, sample6.bat) which will be executed one after the other. I have an if condition in the 3rd batch file(sample3.bat).

If this IF condition failed I want to block the execution of remaining batch files (sample4.bat, sample5.bat, sample6.bat)

Please help.. Thanks in advance

Why are they all SEPARATE? Why cannot the CODE be in one file?


Discussion

No Comment Found