Forum Discussion

alex_jones's avatar
alex_jones
Occasional Contributor
10 years ago

Get return code from a c# console application

Hello,



I have written a small console application that, when it has completed successfully, returns 0 and when it fails return 1.



I created a keyword test which runs the console application followed by a Set Variable Value "LastResult".



The variable is an integer. The variable doesn't have the value that I'm returning, just the default value I set in TC.



How can I get the variable to have the value returned from the console application.



Thanks



1 Reply

  • alex_jones's avatar
    alex_jones
    Occasional Contributor
    I have solved my issue by reading the Checking the Completion Status section of the Interacting with console windows chapter in the manual.



    Thanks,



    Alex