LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

one button dialog in LabView dll not working from CVI

I've been having trouble getting LabView DLLs that use the One Button Dialog to function correctly when called from LabWindows/CVI.

I'm currently using LabView 2014 SP1 and LabWindows/CVI 2013 SP2.

For a simple test, I made the following VI into a DLL in LabView:

A+B LV.png

 

The basic concept being that you can optionally display a popup message of the result.  (I did not include error handling to simplify the function.)

The DLL is created with the appropriate header file:

DLL.png

 

I then created a very simple executable in LabWindows/CVI to test the DLL:

 

C.png

If I run the code above going line by line in debug mode, I will get the right result for "C" before exiting.  If I set the third parameter to "1" and run the code, I get the following popup and the program hangs indefinitely:

bad.PNG


I have also noted that calling the DLL from a labview VI does not have this problem and the functionality is as would be expected.

 

Why does CVI have issues displaying the popup?  Is it something to do with the temporary .exe that is being created?

 

Further, if I build a release executable and run, I get this:

RTE.png

The lvrt.dll file is in that directory, and I have been using 2014 for the development, so I have no idea what's going on here.  Would a reinstall make any difference?

Thanks

 

 

 

0 Kudos
Message 1 of 2
(3,878 Views)

I found a previous service request where the issue was explained as a threading conflict between the two UIs. It seemed to have been solved by calling the DLL in a separate thread.

Matt J | National Instruments | CLA
0 Kudos
Message 2 of 2
(3,864 Views)