LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Pull the error code off of an error

I am rewriting some old Labview 5.0 code and I am trying to use the serial port. The old code used the serial port config.vi not the VISA Serial config. They pulled an error code off of the old serial config so that if an error occured the code would not execute. Basically it would give a true or false based on if there was an error and that fed into a case structure. Is there a better way of error testing? I am attaching the vi for better explanation hopefully.
0 Kudos
Message 1 of 3
(2,640 Views)
This is a pretty standard architecture. You can do the same thing off of the VISA Serial Config.vi by moving the unbundle out of the TRUE case and to the error output node of the config vi. Then just use the Status cluster to determine which case to use, versus the <0 function.


2006 Ultimate LabVIEW G-eek.

Message 2 of 3
(2,640 Views)
Thanks, I will have to try this. I actually just went ahead and rewrote the code, but it is always good to get some new knowledge. Thanks again!
0 Kudos
Message 3 of 3
(2,640 Views)