03-01-2018 08:12 AM - edited 03-01-2018 08:23 AM
i use cvi for Runing a seqFile but when i click close allways i get this message :
" this execution is currently running . what would you Like to do?
and how can i hide this message ? and whats the best way to stop and close teststand ? and what's the function should be used ?
03-01-2018 08:49 AM
Hiding the message doesn't solve it.
The question must be: Why is there still an execution running when you click "close"?
In most situations, disabling the close button as long as an execution is running is the best solution. Do not forget to re-enable it once the (last) execution finishes!
Another option is to not shutdown TS directly with the close button but to initiate a Terminate All.
03-01-2018 08:54 AM
You can look at the shipping example to see how they do it: C:\Program Files (x86)\National Instruments\TestStand 2014\UserInterfaces\Simple\CVI\Source Code
I'm not as proficient with CVI but it looks like they trigger the ExitApplication() function when the user closes the UI. Which in turn is calling this function: TSUI_ApplicationMgrShutdown(gMainWindow.applicationMgr, &errorInfo, &canExitNow)
Then they monitor for the shutdown event and safely close out the window.
Problem is you will still most likely get the dialog from your post if an execution is running. If you don't want that dialog then make sure that all executions are completed before allowing the user to close the UI. That dialog is part of the TSUI_ApplicationMgrShutdown routine. TestStand needs to know what you want to do if there is an open execution.
Hope this helps,