10-08-2012 02:56 AM
Hi all, I have used source code to generate an exe file. And I also load dynamic vi using this exe file. However, right now it cannot be closed properly by clicking "X" on top right corner. I think it is caused by loading dynamic vi but do not know how to solve it. Could you help me about this? Thank you!
10-08-2012 04:33 AM
It sounds like you may not be closing the reference to the vi.
Look at the "dynamic load example.vi" that ships with labview.
Also, one other think that may catch you out is if you are building the path to your vi dynamically, this example will help.
Hope this helps.
10-08-2012 04:40 AM
hi aCe, I do not have dynamic load example.vi, could you upload it? Thank you!
10-08-2012 04:48 AM
Its here:
C:\Program Files\National Instruments\LabVIEW 2011\examples\viserver\dynload.llb\Dynamic Load Example.vi
10-08-2012 04:59 AM
Hi aCe, I read the example but am not sure if it is applicable in my case. Here is my related code. I used sub-panel function to include a external vi. Then when build exe I used it as "Always included". Could you advise what I should do to close it properly? Thank you!
10-08-2012 05:06 AM
The reference you opened to the dynamic vi needs to be closed, the close reference in your flat sequence is disabled and also your reference is going else where as well. Without seeing the rest of the code, there is no way to comment further.
Look at this as well: C:\Program Files\National Instruments\LabVIEW 2011\examples\general\controls\subpanel.llb\Simple Subpanel.vi
10-08-2012 05:43 AM
Hi aCe, I have enabled the close reference that was connected there, And the code you cannot see from the screen was the other connections in this case structure. But every connection is exactly the same as this flat sequence. But I still cannot close the exe properly, could you advise? Thank you!