LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Subsequent calls to DLL function do not stop execution at RunUserInterface call.

The fist time the DLL function is called everything behaves as expected. QuitUserInterface is called later and my function returns to TestStand. I have set the option in TestStand to not unlaod the DLL becuase I want to keep some values in global variables. The problem is that in all subsequent calls to the function from TestStand execution does not stop at RunUserInterface like it did originally, but goes right through to my cleanup code.

My work around is to put in a message popup right after, but I am not satisfied with that solution. What else might I be able to do?
0 Kudos
Message 1 of 2
(2,650 Views)
Hello GDTestEng,

Thanks for contacting National Instruments.

I'm not exactly sure how your run options for are set for the Load and Unload of each step that calls your CVI DLL in your TestStand sequence. If you set those options for each step to these values, the DLL is loaded/unloaded for each sequence execution (i.e. for each UUT iteration through the sequence):

Load = Preload when execution begins
Unload = Unload after sequence executes

However, if you set the Unload option for the LAST step that calls this DLL to "Unload after sequence file is closed", then the DLL is not loaded/unloaded between sequence executions.

As for the problem of not stopping execution at the RunUserInterface call at subsequent iterations... I'm not sure
, so I'm attaching a zipfile containing a small CVI 6.0 DLL application and TestStand 2.0.1 sequence that I think accomplishes what you're trying to do.

I hope this helps with the problems you've run into!

Regards,
David McClelland
National Instruments - Applications Engineering
0 Kudos
Message 2 of 2
(2,650 Views)