ALERT: Some images may not load properly within the Knowledge Base Article. If you see a broken image, please right-click and select 'Open image in a new tab'. We apologize for this inconvenience.

Javelin - Invoke Process not failing when the .bat file fails


Article ID: 198624


Updated On:


CA Test Data Manager (Data Finder / Grid Tools)


I am trying to call a .bat file from the Invoke Process component in Javelin. Although the Invoke process functionality is working fine if the bat file executes successfully, the workflow is getting completed even if .bat file fails.

Below is the .bat file content. I am trying to fail the .bat file explicitly giving Exit code as 1 or anything apart from exit code 0 which signifies batch success.
Let me know what can be done to fail the javelin workflow.

Please note I have selected 'ContinueOnError' property of Invoke Process as 'False'.

echo "Start creating CD_ALL.xlsx">>C:\log.txt
cscript C:\MergeAll.vbs
if %errorlevel% NEQ 10 GOTO :error

GOTO :success
echo "There was an error.">>C:\log.txt
echo "Exit the program" >>C:\log.txt

echo "CD_ALL Macro run completed">>>C:\log.txt


Javelin 4.9.X
TDM 4.8


By default the Invoke Process activity does not take action on exit code.
you can setup a variable to capture the exit code and then take action on that.