06-04-2015 08:55 AM
Hello,
I am using the Quit labVIEW to close down an application when the VI is built into executable. If stop LabVIEW is used the application just stops and leaves the window open. When the Quit LabVIEW function is used in an executable the application closes down completely.
In the current app I am developing (Windows 7 - LV2014SP1) I have isolated the Quit LabVIEW function as the source of the Crash Report I am receiving after I exit the application. I inpsected the crash report and there was mention of a thread that did not have appropriate access. So I ran the same executable with Adminstrator privledge and the error went away. It appears the application I am developing does not have sufficient privledge to close itself down and this is generating the Crash Report.
I have used the Quit LabVIEW function for many applications in the past without issue. I have not confirmed yet whether the problem is specfic to the current application I am developing or to LV2014SP!.
thanks for any help with resolving this issue,
- Troy
Solved! Go to Solution.
06-04-2015 09:07 AM
Your lesson here should be to stop using the Quit LabVIEW function. You need to properly close out all of your references and close your front panels. That will shut down the RTE (when there are no front panels open and all applications have stopped).
06-04-2015 09:48 AM
The method I described was recommended previously. It was necessary to determine whether the application was VI or EXE and either do STOP or Quit LabVIEW. Closing the front panel was something the Quit LabVIEW function handled. If the STOP function is used in an executable the apllication stops but the front panel remains open.
I implemented a close front panel using the Invoke Node function and was able to close the application as you suggested.
Wasn't there previously some issue with using Invoke Node in executables?
thanks for the help,
- Troy
06-04-2015 09:54 AM
TroyR wrote:
Wasn't there previously some issue with using Invoke Node in executables?
Not that I am aware of. But here is my trick for shutting down an application. I put the FrontPanel Close method inside of a Conditional Diagram Disable. The invoke node only goes into the RunTime Engine == True case. This way, the front panel is not closed if you are in the development environment.