Using fp to exit a batch process
Kenneth Brody
kenbrody at spamcop.net
Fri Jun 7 07:36:06 PDT 2013
On 6/7/2013 9:09 AM, Richard Hane wrote:
> Windows 7, fpODBC 1.0.15 network 16 user
>
> Situation: Running a long batch file containing fp processes. If in
> processing a condition is found, I would like to exit not only the
> current process (easy with 'Exit'); but also totally exit the batch file.
> In short do not let the balance of the batch file run.
>
> I think I could issue a system command to move to another directory (away
> from the batch file).
>
> Does anyone have a better suggestion?
As Richard Kreiss suggested, use "EXIT nnn" and "IF ERRORLEVEL".
Using "a system command to move to another directory (away from the batch
file)" would be meaningless, since you don't need to be in the same
directory as the bat file since at least MS-DOS 5 days, if not earlier.
(Not to mention that having a child process move to a different directory
hasn't affected the parent process on Windows for a couple of decades.)
--
Kenneth Brody
More information about the Filepro-list
mailing list