LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

LabWindows/CVI application popup causing issues

Hello,

 

I had created an application in Teststand that was using a LabWindows/CVI dll that was allowing a popup to be launched that allows File Explorer to open and select a file. It was working two weeks ago when I checked but hadn't tried it since then. After that I hadn't changed my code at all, but had installed Teststand 2019, LabWindows/CVI 2019 and LabVIEW 2019 in addition to the 2013 versions that existed. It seems as though installing the other versions of the NI Tools messed up something that I am unable to fix. Please let me know what could be the cause of this issue. I will attach the error message below.

0 Kudos
Message 1 of 2
(1,167 Views)

Popup dialogues require a specific multithreading model to be run and throw an error if run in a different one. I don't know why you didn't see the error before but you mention the installation of a newer CVI release and this could be the reason: installing a new IDE updates the CVI Run-time Engine as well so the switch from 2013 RTE to 2019 could explain this.

 

A simple search on the forum with "MTA" keyword will show you several discussions where you can find explanations and solutions. but basically you need to initialize your thread in a specific way to run FileSelectPopup safely. This could conflict with other functions you are calling in your code, as a last resource you may be forced to spawn a new thread just to handle the popup in a proper way.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 2 of 2
(1,122 Views)