LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Modal Dialog will not close until calling VI stops

I figure I am missing something very trivial, but it is escaping me at the moment.

 

The calling VI is actually a subpanel, and there are 4 sub panels on my GUI.  So the dialog gets a refence to the calling vi (in the subpanel), and then centers itself on the calling VI.

 

Once you press the OK button, the dialog should close, but it does not until much later.  I can duplicate the issue with a simple calling VI

 

The QR Dialog Testing.vi calls the dialog subvi, enter any value for the QR code, and then hit the OK button on the dialog.   

 

The dialog will remain open (with the OK button depressed), until the 5 sec timer runs out on the QR Dialog Testing vi and that VI stops executing.

 

Kenny_K_0-1618423654214.png

 

Dialog Block Diagram

 

Kenny_K_1-1618423776149.png

 

 

 

Attached VIs are saved in LV 2020 and 2018

 

Kenny

0 Kudos
Message 1 of 7
(1,495 Views)
Hi Kenny, the dialog closed right after I clicked the OK button. (LV 2020). I had to delete the green "Align" VI because I don't have it installed. Can you try again with that VI deleted? Just wire FP.Winbounds straight across.
0 Kudos
Message 2 of 7
(1,457 Views)

I am still seeing the issue unfortunately.   I have this version of LV 2020.  I am seeing the same issue in 2018 on another Pc I have, with and without the Snap to Center VI.

 

FYI - The Snap to Center VI is part of the LavaG UI tools Package.

Kenny_K_0-1618431916119.png

 

 

 

Kenny_K_0-1618430078463.png

 

I have tried to mass compile the VI as well, and rebooted LV and the PC.

 

I attached a video of what I am seeing.

 

 

 

Kenny

0 Kudos
Message 3 of 7
(1,434 Views)

I ended up recreating the same dialog from scratch, and now it works.......

 

Not sure what happened, I will see if I can find the root cause.

 

 

Kenny

0 Kudos
Message 4 of 7
(1,421 Views)

I'm not quite sure what is going on here, but it seems related to the mouse down event. If you change the "OK Button: Mouse down" even to "OK Button: Value change" the VI closes without the delay. Seems like the mouse down does some kind of other process that is preventing the window for closing. 

0 Kudos
Message 5 of 7
(1,417 Views)

I am seeing some different, strange, behavior. If I type some text into the string control and then click the OK button shortly after, it won't register. If I wait some time, like 1.5 to 2 seconds, it will register the click. This happens on your VI, as well as a new VI I just made, and it even happens in edit mode.

However, I right-clicked the OK button and went to properties>>key navigation, and set the Toggle on the "Return" key. Then when I enter text into the string and press Enter/Return, it hits the OK button immediately. This won't trigger an event in your VI because you have it set to trigger on "Mouse Down" for the OK button, I just thought it was interesting.

0 Kudos
Message 6 of 7
(1,412 Views)

Search the Forums for an example of my dialog template.   They are not quite as easy to use for a multi linguist as AQ's Three Button Dialog Core.vi but, .....

A .vim ,without polling, replacement to the hideous TBD Core.vi is possible.   AND IMHO should be developed!

 

You are 75% there 


"Should be" isn't "Is" -Jay
0 Kudos
Message 7 of 7
(1,395 Views)