LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Error 1160. Undefined error. Code:1125

I've been trying to learn LabVIEW by following a simple example in a Sirah Dye Laser Programmer's Guide of how to append a user defined menu item to their existing program. It involves creating a case structure with reference control inputs "laser" (from their laser library), "menu" and "configure", along with the "control" string and "error in (no error)" cluster - and the corresponding indicator outputs. Four cases are defined:

Default: all commands pass unchanged

AppInit: initialises application by diverting the menu and error wires through the menu VI, which has Item tag:_Sample, Item name:Sample and after item:_Motor constant terminals. The "catched" command is given an empty string.

Sample: displays a dialog box in which a one button dialog VI has Message: This is a sample application and Button: I see constant terminals. The "catched" command is given an empty string.

AppClose: closes the application. All commands pass unchanged, save for the command out, which is given an empty string in place of the "catched" command.

When I run the VI on its own, I get an error 1160 message on the output of the Menu VI. I assume this is because I have no reference information input from the existing application. When I define the input and output ports in the connector pane and save the VI in a library file that the Sirah Control application can read, I get a message that reads "An undefined error was detected. Program aborts now" and an error log with the message Undefined Error Encountered. Code:1125. Source: "Open VI Reference in Read user VI.vi ->Execution Main.vi", after the application closes.

Can you help?
0 Kudos
Message 1 of 2
(3,402 Views)
Hi Scohop,

I've been playing around with your code and trying to replicate the error. I used a parent VI with a run-time menu and was able to use your sub-vi to add items to it programmatically with no errors (as long as I provided a menu reference). From a LabVIEW perspective, I can't really see anything wrong with your code or any reason when there would be a problem, although I don't have the supporting files (references, parent VIs, run-time menus) to properly test it.

Furthermore, it sounds like the error is being generated by the program you are running and not LabVIEW itself, so with no experience of the Sirah Dye Laser Programmer's Guide I can't diagnose the issue.

If you can post more supporting files (bearing in mind copyright) I may be able to help, otherwise perhaps someone else that has worked on these exercises can offer assistance.

Regards,
Tom

Applications Engineering, NI UK
Message 2 of 2
(3,379 Views)