LabVIEW Shortcut Menu Plug-Ins

cancel
Showing results for 
Search instead for 
Did you mean: 

Selected Items in plugin script have no marching ants when script terminates.

Using the Make Selection method in my plugin script does result in objects being selected when the script ends, but they do not appear with marching ants, or even with a dotted outline. 

 

If I apply the method Move Selection To Front, I can consistently get non-marching ants (aka dotted line) on the selected objects when my script ends, but mousing over the selected objects causes the dotted line to disappear. 

 

In some cases Move Selection To Back gives me marching ants. I haven't hit on a method that does so consistently.

 

Is this problem specific to the plugin framework?

_____________
Creator of the BundleMagic plugin for LabVIEW!
Comments
AristosQueue (NI)
NI Employee (retired)
on
If my memory serves, you're seeing a feature, not a bug. If you were a biologist, you'd know that ants are not bugs. :-) Joking aside: do your right click operation, then click on the window title bar of the VI. Do the ants start marching? I seem to recall something about the ants being suppressed during scripting operations unless something happened to give the window focus or something like that. I'd have to go hunt around for details (either with teammates or the source code). Try the title bar test. If that works, then use the property on the VI's panel or diagram to bring the window to front. Might work.
littlesphaeroid
Active Participant
Active Participant
on

Title bar click does not cause ants to go a-marchin. 😞

_____________
Creator of the BundleMagic plugin for LabVIEW!
AristosQueue (NI)
NI Employee (retired)
on
Hm... I've got no explanation then. Sounds like a bug at this point.
wiebe@CARYA
Knight of NI Knight of NI
Knight of NI
on

I used a Flash.vi dummy. This shows and hides it's front panel when called. It doesn't do anything else. When a new selection is made, simply call the VI. It will flash (show and hide) and the DUT vi is activated again.

 

Used here: https://forums.ni.com/t5/LabVIEW-Shortcut-Menu-Plug-Ins/Select-parent-control/ta-p/3950888

 

For me, this triggered the ants to march.

 

EDIT: I think the problem is that VI is activated, and the scripting action doesn't trigger the ants. Activating the VI doesn't trigger the ants, as the VI was activated before. So there's no state change. The dummy popup deactivates the DUT, that activates it again, and the ants are triggered by the state change.

littlesphaeroid
Active Participant
Active Participant
on

I was able to do something similar to your flash dummy VI. I tried many permutations of your trick, and I can now consistently get non-marching ants An improvement! Thank you. 

_____________
Creator of the BundleMagic plugin for LabVIEW!
Contributors