LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

error handling with xcontrols

What is the best way to do error handling with xcontrols?  There is no obvious way to return an error cluster back.

 I've thought of four possible methods:

1) Incorporating the error cluster into the xcontrol's data cluster.  But then the error will only be handled if the xcontrol's data is explicitly read.  Since xcontrols have a lot of other functions, it might never be read.

2)Pop a dialog box with the error information.  This lead to repeated LabVIEW crashes  (100% CPU utilization, etc.)  (I'm using 8.2)

3) Write the error information to a global.  This seems to work, but it means that I have to poll the global.

4) Use a notifier.  I haven't tried this yet, so I don't know if it will work.

It doesn't help that xcontrols are hard to debug.




0 Kudos
Message 1 of 2
(2,591 Views)
Hi Joel,

what you could do is launch a VI in the init-state of the XControl via VI-server dynamically. And feed errors via a queue to this VI. If you kill the queue in the final state of the Xcontrol, the queue will generate an error and you can close the error-VI

Ton
Free Code Capture Tool! Version 2.1.3 with comments, web-upload, back-save and snippets!
Nederlandse LabVIEW user groep www.lvug.nl
My LabVIEW Ideas

LabVIEW, programming like it should be!
0 Kudos
Message 2 of 2
(2,579 Views)