05-29-2015 07:49 AM
I have inherited code that has a lot of stuff running in parallel. Under normal operation I make sure that I close everything, however, every once in a while one of the loops does not close. If I use the stop feature, the software reports a bug sometimes when the operator closes labview. This is an annoyance that the customer does not like. Is there any way of scheduling a stop for 30 seconds later? Thanks.
05-29-2015 09:18 AM
For more information. I receive this message on exiting labview. Note: This is after the program has stopped and when the operator closes the window display.
a problem caused the program to stop working. Please close the program.
I tried adding the following lines to the ini file but they don't make the message go away.
NIER=False
NIERShowNonFatalDialogOnExit=False
NIERNonFatalAutoSend=false
05-29-2015 01:27 PM
Can you use the Window Appearance customization to remove the Stop button from all interface VIs, and then add a control button to them that calls the "Stop" function programmatically? With the desired delay.
It sounds like there's maybe a handle to a driver or something that LabVIEW doesn't close properly when using the Stop button.
05-29-2015 01:49 PM
That "Stop Sign" is really an ABORT you should expect bad think may happen
To Quote EdDicken's sig line
"Using the Abort button to stop a vi is like using a tree to stop your car. It works but there may be consequences!"
So do rip the abort button of the FP and then we need to asses why not all loops "get the message" that they need to stop.
05-29-2015 02:25 PM
The customer is okay with the VI stopping 30 seconds after pressing the button? Apparently there's a race condition that occasionally prevents everything from shutting down. It would help tremendously if you could post some code, or even explain how each loop shuts itself down.
05-29-2015 02:27 PM
The 30 seconds is for a secondary stop in case the primary mechanism of closing everything out does not work. I want to close my software out the normal way 99% of the time, but that 1% of the time I want to make sure one of the many parallel vis don't hang the shut down process up.
05-29-2015 02:32 PM
That's the reason why we need to see code or at least an explanation about how each loop shuts down. Obviously the stop condition(s) of at least one loop is sometimes not met. Trying to cover up the problem should be the last (last, last, last) resort, not the first.
05-29-2015 02:58 PM
I have about 50 of them. Definately not my style of coding.
05-29-2015 09:59 PM
So no, you won't post the code so we have a chance to help you figure this out?
05-30-2015 12:06 AM
Or even let us know the exit strategy?