LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Exit Code or Return Code Status Bit Returned from LabVIEW

Hi All,

 

Has anyone tried using what's described here:

 

http://digital.ni.com/public.nsf/allkb/E5CC7B2073D4FC1A8625742D006CE492

 

If so, I'd be grateful if you could post your code - I can't seem to get it to work.

 

I've attached my VI, and the batch file that calls the built EXE version of it.

 

I would hope that when run from the command prompt, example.bat would echo "1", as this is what I'm trying to write to "status".

 

Thanks,

 

Dan

Dan
CLD
0 Kudos
Message 1 of 3
(3,005 Views)
That knowledge base article is really old. LabVIEW could have changed, Windows has definitely changed. I'd start from the Windows side first and see if the recommendations are still valid.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 2 of 3
(2,968 Views)

It doesn't look like it's possible - perhaps it's a good idea for the NI Ideas Exchange. I would have expected it to be an Application property/method you could write to, just like you can read in command-line arguments on launch.

 

Unhelpful, but as a point of interest, it does look like it is possible (in some form) in TestStand - http://zone.ni.com/reference/en-XX/help/370052M-01/tsuiref/reftopics/applicationmgr_exitcode_p/

 

Using the solution in the article does not seem like a good idea as it will immediately kill your application - if you're sure everything has shut down correctly then perhaps you could do it as the last call but generally it's better to close all your front panels and let LabVIEW exit gracefully.

 

 


LabVIEW Champion, CLA, CLED, CTD
(blog)
0 Kudos
Message 3 of 3
(2,926 Views)