LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Why do the LauchExternal function return -3?THank you

In my program when the data is more than the alarm setpoint,  I wanna to lauch a external vioce player software beyond the CVI to notice the user.
So I use the function LauchExternal**  (I am not sure the type of this function  <SCRIPT language=JavaScript type=text/javascript>rwWord("syntax");</SCRIPT> syntax, you can Crtl+p to find the exactly type of this function);
IN my first PC, if the vioce player does not exist, the software developed by CVI can works well, just does not  make the sound.
But in another PC of mine, the software developed by CVI happens a error. In the debug mode, I can see the return value of this function is -3
 
 
What is the reason for the difference between of the two PC? Thank you
 
0 Kudos
Message 1 of 3
(3,049 Views)

For the LaunchExternal function -3 as a return code means "File not found".

So, probably you have mistyped the file path or the file (the executable) does not exist where you expect it to be.

Hope this helps.

S. Eren BALCI
IMESTEK
0 Kudos
Message 2 of 3
(3,039 Views)

It seems as though the difference between the two PCs' behaviour is because one CVI program is running in Release mode (where non-fatal library errors are ignored) and the other is in Debug (where such error cause a break).

JR

0 Kudos
Message 3 of 3
(3,035 Views)