04-02-2010 08:42 AM
With the event structure of that VI. Which calls the panel close of the VI that called it, then the panel close of itself. Just like I showed.
04-02-2010 08:45 AM
04-02-2010 09:10 AM
04-02-2010 06:49 PM
When using the cross (x) to close UI VI the window closes but the application hangs in the Task Bar (Manager).
I'm using the Application Closed? event in the UI VI. Obviously the calling VI is not getting shut-down.
In the UI VI this is what I do for Event Application Closed?
1. Disregard with False.
2. Stop the While Loop.
3. Close the Front Panel.
4. Exit LV VI.
04-02-2010 07:22 PM
Have you read anything that I or others have written in our messages?
I have never used Application Instance Close. I said to use Panel Close? event. That is the one associated with the window X. Wire a True to the Discard? terminal. You don't want the panel to actually close until you've done all of your cleanup code.
To close the calling VI, you will have to use a reference to that VI and call the Front Panel Close method. Then when that is done, then you can call the Front Panel Close method for the UI VI that you have open. You can pass in a reference to the calling VI through the connector panel of the called VI when you call the subVI.
You still haven't said why you even have a calling VI.
04-02-2010 10:38 PM
It is clear to me now. I was simply using the wrong Event.
I was doing the other things you suggested such as passing the calling VI ref. That's why I gave you Kudos for the suggestion.
Works great. Thanks for your help.
04-02-2010 10:47 PM
04-02-2010 10:49 PM - edited 04-02-2010 10:50 PM
04-02-2010 10:51 PM
I haven't heard of any problems with that method.
If you are having a problem, start a new thread and attach a VI that demonstrates it. Perhaps something else is going on in your VI that is causing you a problem.
04-03-2010 01:49 AM