NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Modal Popup Issues

I have a VI (A.vi) that I call from a TestStand pass/fail step.  That VI's front panel does not appear (intentionally) when the step is run.  However, there is a subVI (B.vi) called from A that pops up a Yes/No dialog to the user.  I set the Window Appearance (see atttachment) so as to display when called.  When I run the test from TestStand, it works the first time - the dialog appears in front of my Test Executive and the test works great.  If I try running it again, the dialog appears behind the test executive - the code executes just fine, it's just not Modal, as it was the first time it was run.
0 Kudos
Message 1 of 21
(4,645 Views)
Hey Mr. Bean,

I would recommend using the Start Modal and End Modal VI's from the TestStand palette.  These VI's are intended to display a message that is modal to the TestStand application.
Thanks,

Andy McRorie
NI R&D
0 Kudos
Message 2 of 21
(4,608 Views)

While looking for something else, I found a snippet of code I thought might help, but it didn't.  Any idea why?

 

 

0 Kudos
Message 3 of 21
(4,563 Views)

Hey Mr. Bean,

I would recommend using the Start Modal and End Modal VI's from the TestStand palette.  These VI's are intended to display a message that is modal to the TestStand application.

Regards,

Message Edited by Sam R on 03-12-2007 01:06 PM

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
0 Kudos
Message 4 of 21
(4,558 Views)

The reason that your FP.IsFrontmost property doesn't work is because it will only make the VI that code resides in modal to LabVIEW only.  LabVIEW and TestStand are seperate applications and therefore you have to do special calls (i.e. the TestStand palette Start and Stop Modal VIs) in your VI to make it modal to TestStand.  Otherwise, if you use the IsFrontmost property, you are just making the VI modal to any other LabVIEW VIs.

Hopefully this clears up the confusion you have.

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
0 Kudos
Message 5 of 21
(4,539 Views)

I have a similar problem; I am using TS3.5 and LV 8.20. I have my adapter set to LV Dev System. I am calling a VI in a callback, the first time it works fine but the second it appears modal to TestStand but not modal to the LV Application Window (See image 1) and the only way to get out of that state is terminating LV which crashes the whole Operator Interface app (See image 2)

 

I tried mrbean's solution (FP.isfrontmost) and for some milliseconds the VI appears over the LV App Window but the somehow the LV App Window comes back to the front and I have the same problem when trying to access the Operator Interface

 

Then I tried the TS3.5 Start and Stop modal and they work but the VI's Front panel blinks when they are shown... any clue???

Download All
0 Kudos
Message 6 of 21
(4,518 Views)
I guesed it was a race condition so I added delays and this is what I got, the front panel is over the LV App Window but it is disabled, if I click over it the LV App Window becomes modal... any clue?
0 Kudos
Message 7 of 21
(4,512 Views)
I don't know how you could have a race condition if you use the start and stop modal functions in the correct manner. Each should only be called once. The start modal at the beginning of the VI and the stop modal as the last thing. Race conditions are usually associated with local variables. Are you using those in some way? I only hve 7.1 on this pc, posting an image of the block diagram will help a lot more than an image of a front panel.
0 Kudos
Message 8 of 21
(4,503 Views)
Yes I am passing locals to the VI, that maybe the reason....
 
Another thing is that when I use the Start Modal the VI appears on the top for several milliseconds then disappears and it appears again and it looks like it is blinking, Stop Modal works fine.
0 Kudos
Message 9 of 21
(4,475 Views)
Hey N,

Please post your sequence and the VI that you are using that shows this behavior.
Thanks,

Andy McRorie
NI R&D
0 Kudos
Message 10 of 21
(4,466 Views)