LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why does my .LLB Application take so long to EXIT ?

I have an (4 MegaByte) AutoRun .LLB file running under LabView 6i and Win N/T 4.0. When I execute the EXIT Function a Window Frame appears with the name of the Top Level VI that Started the Application. The main body of the window is transparent and you can see the desktop. The application will sit like this for several minutes, even up to an hour and then exit normally. If I use Task Manager to force the task to exit then I get an error the very next time I load the .LLB file. "c:\winnt\system32\NIPALU.DLL Process Terminated Abnormally". Then the next time the .LLB will load OK.
Any ideas ?
0 Kudos
Message 1 of 8
(3,302 Views)
How do you exit? Perhaps you are forcing something and stopping the vi in a wrong way, file size should not be a problem, I've made llb-s up to 25 MB and exit correctly under LabVIEW 5.0.1f1. Try to follow your code's way using highlight execution, and see what happens when you exit. Hope this helps.
0 Kudos
Message 2 of 8
(3,302 Views)
I have a 3 Step Sequence.

Step 0 = Initialize
Step 1 = While Loops controlled by OK_TO_RUN Global
Step 2 = EXIT Function

When it is time to stop, I set the OK_TO_RUN Global to False. All While Loops will terminate and then EXIT function is processed.
0 Kudos
Message 5 of 8
(3,302 Views)
Gorka Larrea,

More Background ...
Our company paid another company to develop this application for which I am now responsible. Therefore I am still learning how this application works. The Vendor knows of the very slow EXIT issue but has no solution.

This is what I found ...

The are twenty different calls to the "Open VI Reference" function for the currently displayed Control Panel (one of the calls appears to execute 5 times / second). This appears to then be setting the Control Panels Size and FrontMost attrtibutes. BUT, there is NEVER any call to "Close LV Object Reference". I added a "Close LV Object Reference" to EVERY "Open VI Reference" function. The application is now closing in THREE SECONDS.

I am assuming the Open RefNum Table was HUGE bec
ause the RefNums were never closed and would be closed automatically be Closed by the EXIT Function. Hence very long EXIT times.

I *think* (hope) this is the fix.

I am going to let the Appl run over night and see what happens tomorrow morning.

Thanks for your help ...
0 Kudos
Message 7 of 8
(3,302 Views)
Opening and closing VI references seems to consume a considerable amount of time if repeated once and again, so I recommend you to simply open ONE reference to the vi outside the while/for loop, and pass it through. You should close this reference when exiting the program. that will avoid opening & closig references all time... About your program, as long as I understood you, you are using sequences, well, this could be good if dataflow goes in that sense, else, you should use state machines selecting the action you need at every loop, not repeating initialize state every time, including when you exit... well hope this has helped you as I think the other answers did... Good Luck
0 Kudos
Message 8 of 8
(3,302 Views)
Make sure you stop all the while loops before exit.
0 Kudos
Message 3 of 8
(3,302 Views)
Some Background. I have a 3 step Sequence.

Step 0 = Initialize
Step 1 = Main While Loops with an OK_TO_RUN Global
Step 2 = EXIT Function

When it is time to stop I set OK_TO_RUN to FALSE and the While Loops terminate and the Final Step (#2) of the Sequence runs just an EXIT Function. Cannot get to the Exit function unless all of the Whiles Terminate.
0 Kudos
Message 4 of 8
(3,302 Views)
Alberto,

More Background ...
Our company paid another company to develop this application for which I am now responsible. Therefore I still learning how this application it works. The Vendor knows of the very slow EXIT issue but has no solution.

This is what I found ...

The are twenty different calls to the "Open VI Reference" function for the currently displayed Control Panel (one of the calls appears to execute 5 times / second). This appears to then be setting the Control Panels Size and FrontMost attrtibutes. BUT, there is NEVER any call to "Close LV Object Reference". I added a "Close LV Object Reference" to EVERY "Open VI Reference" function. The application is now closing in THREE SECONDS.

I am assuming the Open RefNum Table was HUGE because
the RefNums were never closed and would be closed automatically be Closed by the EXIT Function. Hence very long EXIT times.

What do think ?
0 Kudos
Message 6 of 8
(3,302 Views)