LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

locate vi clones

I would like to find any VI clones that are in memory, but the App property App.AllVIs doesn't show any clones.

How can I get those?

 

 

Brian Smith
Advanced Light Source
Lawrence Berkeley National Laboratory
0 Kudos
Message 1 of 9
(4,832 Views)

You should give Kudos to this idea.

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


0 Kudos
Message 2 of 9
(4,828 Views)

So the answer is that it is not possible.

 

Brian Smith
Advanced Light Source
Lawrence Berkeley National Laboratory
0 Kudos
Message 3 of 9
(4,821 Views)

Someone else here might know a workaround

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


0 Kudos
Message 4 of 9
(4,805 Views)

Recent versions of LV shows clones under the view>>relationships menu option.

 

Assuming you want something programmatic, I don't think there's an option. If you go over to the LAVA code repository and find the VI task manager, I believe that does find clones, but I believe it iterates through possible clone names to check if they exist, rather than just getting a list.


___________________
Try to take over the world!
Message 5 of 9
(4,767 Views)

Yes, we want to programatically kill "zombie" clones.

We used to iterate over names too because in the past they were like MyVI.vi:1 MyVI.vi:2 etc, but now, for some unknown reason the numbers are in the 6 millions, e.g. MyVI.vi:6620001  so iteration is not feasable 🙂

 

Brian Smith
Advanced Light Source
Lawrence Berkeley National Laboratory
0 Kudos
Message 6 of 9
(4,730 Views)

I think the numbering scheme changed in some version of LabVIEW (2013?).  There is a vi.lib function buried which find the next available clone number.  Using this you can try to subtract say 1000, and add 1000 and use that as your range of possible clone numbers.  I believe the VI Task Manager uses this function internally.

 

But a better solution I think might be to have these zombies kill themselves.  A reference created in a VI will become invalid if that VI goes Idle.  So you can try to say create a queue reference, and pass that into the clones.  Then in a timeout of something long like 5 seconds, have them check to see if that reference is still valid.  If it isn't then that clone should kill itself.  A functional global could also hold some kind of reference as long as it is created in the main VI.

0 Kudos
Message 7 of 9
(4,664 Views)

Thanks!  This should help.

 

Brian Smith
Advanced Light Source
Lawrence Berkeley National Laboratory
0 Kudos
Message 8 of 9
(4,655 Views)

The clone number VI was posted here by AQ.

0 Kudos
Message 9 of 9
(4,634 Views)