LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
Darin.K

Create Property or Invoke Nodes from Auto-indexed tunnels

Status: Declined
Moved to CAR database. CAR#233635

This one is really getting to me lately.  I have already admitted to being a Right-Click-ohalic, but I am also a script-ohalic and sometimes XML-ohalic.  I have many situations where I have an array of references which I need to iterate over.  Should be very simple, wire the array to a for loop and add the appropriate property or invoke node.  Creating property or invoke nodes from a right-click menu is very efficient, you get the list for whatever reference type you clicked on.  For some reason, auto-indexed tunnels in for loops do not allow you to Create Property for ... or Create Method for...  If you manually wire a property or invoke node to the tunnel you get the proper class so it shouldn't be too hard to skip that step and create the property/method by right-clicking the tunnel.

 

CreatePropertyinForLoop.PNG

20 Comments
JackDunaway
Trusted Enthusiast
Right-clicking the auto-indexed tunnel brings up the Application Control palette, which contains those two nodes (so the nodes are one level deep). Are you talking about bringing both nodes up to the root level of the Context Menu?
JackDunaway
Trusted Enthusiast

Oh wait.... I think I understand, you don't want to create just ANY generic PN or IN and then have to choose it's property/method, you want the choice to be in the creation of the PN or IN itself. After fiddling with it a little while, it occurred to me this is what you're talking about, and that's something I have always intuitively tried to do. Yes, Kudos.

 

This is what we currently have:

 AppControlPalette.png

 

And this is what you are proposing: 

CreateNodeFromRef.png 

 

(And Darin, you're an XML-holic, but you're not at this party?) 

RavensFan
Knight of NI

I think this is a matter of object that is a control vs a wire.  If you right click on an object, you get the context menu where you can create a property node or invoke method for that object (also, local variable or reference).  If you right click on a wire coming from that object, you don't get those choices.

 

If your right click on the auto-indexing tunnel, you basically get the same context menu as if you right clicked on a wire which doesn't have those choices.

 

I think there is a logical reason for that.  If your right click on an object and choose one of those items, you get a node that is implicitly linked to the object.  (e.g. a property node of that specific boolean control).  Then if you go one step further, you can then disconnect it from the specific control or link it to a different one.  With a wire, or a tunnel, it is just an area of memory that is not implicitly linked to an object, thus you can't create a property node, local variable, reference, or invoke node linked to it since it is not an object.  What I believe Darin is asking for is LabVIEW to be smart enough to know what the class of the wire is and create a property or invoke node of the correct class that can have the reference wire (now a scalar reference as opposed to an array of references outside the loop) that is automatically wired to the reference input of the property node.

 

Now whether LabVIEW can be smart enough to do that, I don't know.  It might be a huge can of worms opened up that the developers of LV would have to handle. 

Message Edited by Ravens Fan on 06-07-2010 11:32 PM
Darin.K
Trusted Enthusiast

I have been an XML-ohalic for about a day and a half now (which is long enough to have done this about a dozen times), so I will probably start paying more attention to the other idea requests. Typically, I reinvent the wheel but recently I have started checking out LV's offering.

 

Jack's picture summed it up nicely.  I would love to right-click the tunnel, select the property or method I want and then get the proper node wired into the tunnel.   I would settle for just wiring a PN or IN to the tunnel straight from the right-click menu, it will get the class right and the node is not too far from the mouse so I don't have to travel too far.  Right now I have to Right-Click, swing over to get the PN, move back to drop it in location, wire to the tunnel, click and select the property.

 

I do have a QD shortcut (surprise, surprise), but while slightly better, it is certainly not natural. 

 

JackDunaway
Trusted Enthusiast

Ravens Fan wrote:

 If you right click on a wire coming from that object, you don't get those choices.


 

Ravens, wrong. Of course, my second picture was a product of MSPaint chicanery, but I generated the Context Menus by right-clicking on the wire coming out of the Ref. The screenshot below has no Paint-Magic, try it in LabVIEW:
 
ReferenceContextMenu.png 
RavensFan
Knight of NI

Actually, your second message came in while I was composing, so none of my comments apply to your post with this screenshot.

 

My comment does apply in LabVIEW in its current state.  And I agree with you that what you want to add is shown in that MSPaint mockup.

AristosQueue (NI)
NI Employee (retired)

I'm going to close this idea as "Already in LabVIEW", but I filed a CAR. Here's what I found with LV 2009:

TerminalPopup.png

The CAR I filed is CAR 233635. For some reason the Create pull-right is not correct on auto-indexing tunnels and only on auto-indexing tunnels. All other tunnels of the VI refnum type are correct, as far as I could find in LV 2009.
 
Message Edited by Aristos Queue on 06-08-2010 09:30 AM
Darin.K
Trusted Enthusiast
Already in LabVIEW?  I wish.  Kidding aside, a final point before this gets banished to the nether regions of known bugs and untrackable CARs.  The array of VI refnums is but an example, same should be verified for all reference types (XML node arrays, control refs, etc.).  Hopefully the same bug afflicts all of them (seems highly likely to me). 
AristosQueue (NI)
NI Employee (retired)

Darin.K wrote:
Already in LabVIEW?  I wish.  Kidding aside, a final point before this gets banished to the nether regions of known bugs and untrackable CARs.  The array of VI refnums is but an example, same should be verified for all reference types (XML node arrays, control refs, etc.).  Hopefully the same bug afflicts all of them (seems highly likely to me). 

Ok, what am I missing? When I try with the various refnums in LabVIEW 2009, I *do* see this behavior for the other reference types. It is only on auto-indexing tunnels that the wrong popup menu is displayed. Maybe I'm not understanding what you're asking for.

Darin.K
Trusted Enthusiast

I think you understand.  Autoindexed tunnels are the only problem spot I have found as well.  I just wanted to make sure that the focus wasn't entirely on arrays of VI refnums, but the most general case of an array of references.  I am 99% certain that the problem lies with the tunnel but just wanted to make sure everything gets checked before declaring the bug fixed.

 

Crossing my fingers for the next patch, this really bugs me.

 

There are other things I would like to create via right-clicking auto-indexed tunnels (to more specific class comes to mind) but I'll save that for another day.