Programmatically Change a Property Node Link to Object

Is there a way to programmatically change a "link" to an object in a property node?  I'm trying to create a user configurable front panel for a project that I'm working on, in which the user can change the caption for numerous controls and indicators.  I would like to set-up a for loop that will take information contained in a string array and change each caption accordingly, instead of having 100 different property nodes on the block diagram.  If you need anymore details, let me know and maybe I can attach a picture to the response.

There's various ways you can do this as far as exact implementation. You will need to use something to identify which control you're dealing with. Attached is one way that uses the control's label as a lookup. You could, for example, use a default caption instead to make it more apparent to the user which control they're specifying to change.
Attachments:
change captions.vi ‏20 KB

Similar Messages

  • Tentative bug report: property node (and other objects) resizes structure in which they are dropped even when this is not needed

    This one has bugged me for a while, so, since I am in a mood to report annoying features, here it is:
    On the diagram, when you drop an object that could have its size increased by user action (for instance a property node in which you chose "Value", which is a short property, but you could later change this to a "longer" one, which admittedly might require more space on the diagram), a case structure in which you drop it, will automatically increase its size.
    Let me illustrate this with ONE example (can be reproduced with other objects such as enums, clusters, etc...).
    Here is a simple diagram:
    Note that I am going to create a property node from the front panel. This, for a reason that makes the beauty of this "feature", is very important. Apparently, if you create the property node from the diagram, nothing weird happens. The exact location where I will drop the node is not very important but needs to be close enough from the border.
    Here is the result (LV 2011 but as I said, this has bugged me for a few versions already):
    Basically, the case structure (and the whole diagram as a matter of fact) has expanded.
    This is particularly annoying, say, when you are creating a diagram with 10 cases in a case structure and you start dropping things such as property nodes in each case: the structure keeps growing, and growing, and growing...
    That also works with Event structure, and I am ready to bet, with other as well.
    As I said, it is also not limited to Property nodes. I have noticed that this happens if you drop a cluster constant that contains an enum (presumably because some of the enumerated strings are longer than others).
    I could speculate why this is the case, but that is not my job.

    Actually, this might not be true. I found a variant of this behavior. With "Place Structure with Auto Grow enabled" unchecked, here is what I observed while dropping a property node on my diagram:
    Before:
    After:
    This is the expected behavior. The Property Node is partly hidden inside the Case Structure I dropped it in. Now that's not what I wanted to do. I wanted to drop it in in the innermost Case Structure:
    The problem is that now this Structure has grown (as has the whole diagram) to leave space for the whole Property Node:
    It is a subtle bug in the sense that I tried to reproduce it on a new VI with a series of nested Case Structures, but it did not result in this behavior.
    Anybody caring to comment?

  • Scripting layer comp property of linked smart object

    How can I through script set the layer comp property of a linked smart object?
    More generally, how can I access a smart object and manipulate it as a document?  I know that I get smart object layers by looking at the kind property, but I don't know what to do with them once I get them.  I'd like to be able to cast the layer to a document object I guess.  Thoughts, anyone?

    Photoshop Feature Requests should be posted over at
    Photoshop Family Customer Community
    But before posting one look around whether one exists already on this issue and add your +1 if it does.

  • All objects property node and grouped objects

    Hi
    I am trying to position a the objects on my GUI in the centre of the screen using property nodes. However, I do not want to have to have a property node for every decoration, image and control. Is there a way that I can group all the objects and then use a property node to position them? I have tried using the all objects property node but none of the indexes seems to apply to my group of objects.
    Help please!
    Many thanks.
    John
    p.s. i have uploaded my test vi's. The chart, decoration and exit button have been grouped. use the control on check.vi to set the object to move. 
    Solved!
    Go to Solution.
    Attachments:
    check.vi ‏13 KB
    run.vi ‏13 KB

    Tab pages are a nice way to group GUI objects.
    Instead of using a decoration,
    use a tab control
    Remove all but the first tab
    Hide the tab
    Set the proprties of the tab control and the control on that page will move, hide, show along with the tab control.
    I hope that helps,
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • Changing the property node from an control in an cluster raises an error in LV2011

    Hi, all
    when I run the code in LV2010 SP1 no problems.
    But in LV2011 it gives an error.
    Is this an BUG
    Attachments:
    test.vi ‏18 KB

    Franzo,
    It certainly is strange.  The error comes from the Width property node, but it occurs when ReadoutMode is clicked.  It does not need to be changed.
    Wrapping it in an event structure (ReadoutMode: Value Change) seems to eliminate the error.
    Questions for someone at NI who knows how these things work internally: It is also interesting that the data type of the Maximum property is always DBL, regardless of the datatype of the control.  Should not a U16 control have a U16 Maximum? And what about the Extended datatype? How can a value larger than the maximum for a DBL be set via a property node of type DBL?
    Lynn

  • How to change the color of Numeric array elements (seperatel​y) programmat​ically using property node??

    For example, i have 3 numeric controls, controlling 3 numeric array elements (Numeric control is connected directly to indicator). Then if i change value in numeric control 1, then the array element No.1 of numeric array should turn red when value exceeds 5. Similarly when i change num control 2 then element 2 of array should turns red when value in num control 1 exceeds 10. Similarly for 3rd element. In other words, i want to control the property of array elements individually through seperate numeric control.
    I have done it for single numeric indicator.i.e. when i change numeric control's values then a single numeric indicator changes values and color (Numeric text BG property) but with array, the color of whole array changes but i want to change color of singles element of array.
    Please help thanks.  
    Solved!
    Go to Solution.

    ...or replace the numerics with clusters that have a numeric and a color box. make the background of the nmeric transparent and slide the color box behind the numeric. Use the color box to control the background color.
    Other alternatives would use a cluster instead of the array or if your req's are really weird "roll-your-own" with a Picture control.
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • Changing data in a linked list object.

    hi,
    i'm still pretty new to java, so bear with me if i am making stupid mistakes, heh.
    i'm having trouble with changing data in an object stored in a singly-linked list. i've created a class that will store polynomials in sorted order (descending) in a singly-linked list. each linked list is one polynomial, and each node references to a polynomial object that stores two ints: the coefficient and the exponent of that term.
    i'm having trouble when it comes to 'collecting like terms,' though. here's a rough skeleton of my code:
    public class Polynomial
    private LinkedList polynoList;
    private LinkedListItr Itr;
    private int coeff;
    private int exponent;
    public Polynomial()
    zeroPolynomial();
    } // this constructor sets up an empty linked list
    public Polynomial( int c, int e )
    coeff = c;
    exponent = e;
    } // this creates a Polynomial object storing the two ints
    public void zeroPolynomial()
    polynoList = new LinkedList();
    theItr = polynoList.zeroth();
    } // this method creates the empty linked list and sets the
    //iterator on the zeroth node.
    //various other methods are here, not relevant to my post
    //this next method is the one i am having trouble with.
    //it takes two ints as parameters, the coefficient
    //and the exponent.
    public void insertTerm( int c, int e )
    //...i have a few if/then statements here
    //so that the terms can be inserted in descending order.
    LinkedListItr tester = polynoList.first();
    //the 'tester' iterator is set on the first node
    //this following if statement retrieves the exponent
    //in the current node by casting the information
    //retrieved from the LinkedList retrieve() method
    //into Polynomial, then compares it to the current
    //exponent. if they are equal, i want to add the
    //coefficients.
    if( e == ((Polynomial)tester.retrieve()).getExp() )
    this.coeff = ((Polynomial)tester.retrieve()).getCoeff() + c;
    //a main method goes here wherein the user can insert
    //terms, print the polynomial, etc.
    }//end Polynomial class
    can anyone help me out? the code i'm using compiles correctly, but it does not change the value of the current coeff variable as i'd like to think it should. any input would be GREATLY appreciated, thanks!

    hey,
    thanks for the reply...
    i am sure that ((Polynomial)tester.retrieve()).getExp() will return an int equal to 'e.' i tried this:
    System.out.println("e="+e);
    System.out.println((Polynomial)tester.retrieve()).getExp());
    if( e == ((Polynomial)tester.retrieve()).getExp() ){
    this.coeff = ((Polynomial)tester.retrieve()).getCoeff() + c;
    System.out.println( "this.coeff = " + this.coeff );
    with that, the output showed that e and the getExp() output were the same. it also showed (as output) that this.coeff did change in value, but when i tried this:
    System.out.println( ((Polynomial)tester.retrieve()).getCoeff() )
    to check if the value changed within the object, it didn't. this.coeff changed, but the actual coeff variable in the object didn't.
    any ideas?

  • Programmatically select a property

    Hello,
    Is it possible to programmatically select a property for a FP object? Properties for which a value change is required are stored in a database (as are the values itself). I can't use a property node because the poperty to change is not fixed and the database can and will be extended in near future.
    Thanks.
    Jan

    That looks to be a very powerful library of VI's that you have linked to tst.
    It looks like they've basically enumerated all the possible properties for all the control types.  They some tricky combination of names and tags and the properties saved as binary data and can parse the file they have to determine which VI's to run and which cases of all the case structures to execute to get to the appropriate property node.
    I'm going to hold on to this library as it could be very helpful in the future.
    I dug into the VI's to see how they were doing this.  I came across a property node with a pink top bar instead of the usual yellow, and I've never seen this before.  What does it mean?
    Attachments:
    [psr] Tree - Cell Colors_BD.png ‏34 KB

  • Use of boolean property node in LabView 6i

    I am running LabView 6i version 6.0.2.
    I am using a reference to a front panel boolean control to stop the execution of a state machine in a subVI.  The subVI has a property node linked to this reference.  This property node shows that it is "Bool", but when I set the property node's element to "value", the value is not a boolean type.  I can't figure out how to set the boolean property node's element so that I can read the state of the boolean control.  How should I configure this?  

    The data type of the value property is a variant.  It is possible to convert a variant to a boolean, but you probably don't want to do that.
    The reason is that you have the mechanical action of the boolean set to "latch ...", and that means that the value property isn't very useful.
    Change the mechanical action to "switch ...", then the value property will be a boolean.
    Note that this means that you will probably have to reset the boolean programatically after the user clicks on it.

  • Setting DAQ channel by property node does not display the value

    I am writing a configuration VI to set channel selection and calibration parameters for an SCXI chassis. I store a default setup in a configuration (ini) file and read that file automatically when the VI is called. The value from the file are set by property nodes using the "Value" property. The values from the file do not display in the DAQ channel selection rings, but the numerical calibration values do display correctly. When I click the down arrow in the channel rings, the correct value displays.
    This behavior exists both in LabView and app-builder EXEs. Also, if I change the property nodes for the DAQ channels to local variables, it works. The Value (signaling) property doesn't cause them to display
    properly either. Why can't I use the property node?

    I don't understand exactly what you are trying to do.
    Please upload a simple VI to demonstrate the behavior you are describing. Remember also to attach the .ini file.
    Best regards,
    Philip C.
    Applications Engineer
    National Instruments
    www.ni.com/ask
    - Philip Courtois, Thinkbot Solutions

  • Grouping property nodes

    Hi there, I'm creating a DAQ application wich reads in 64 channels. Now I want to enable and disable certain items in the front panel using property nodes. You may understand that this would take a lot of time considering it's a 64-channel DAQ application. Does someone has any idea how to group certain front panel objects so I can use only one property node for multiple objects? Or is there another way?
    Another question:
    How can I automaticaly read in a front panel datalog file so it remember names I entered last time I used the application?
    thanks, Bert.

    > What I'm trying to do is:
    > Grey out all 64 channels (1 channel = a string control, numeric
    > indicator and two check boxes) when the acquisition begins (pushing a
    > button). So this would take me 64*4 = 256 property nodes and I thought
    > that there must be an easier way.
    >
    Consider putting the string, numeric, and check boxes in a cluster.
    Place the cluster in an array, and grow it vertically to show 64
    elements. If your layout has several columns, make a copy of the array
    and make say four of them with 16 rows each.
    On the diagram you will be able to set the array properties easily, but
    you will not be able to set properties for individual cells within the
    array.
    This will also affect how you access the controls. Instead of 64x4
    terminals all over the diagram, you will just have the arrays, and you
    can index and unbundle when you want a data element. If you normally
    deal with the 64 displays, this will be very convenient. If you often
    need access to individual elements, I'd recommend making a subVI icon
    where you pass in the array and the index and it returns the four
    subelements as outputs. This will probably clean up your diagram as
    well as simplifying the graying of the display.
    Greg McKaskle

  • Possible Issue with help for "disable property node"

    Hi, In Labview version 9.0 (32-bit) there seems to be a conflict between help info for the Enum constant  as applied to the disable property node . If I right click on a control variable and select create-> property node -> disable. If I then right click on disable -> help for disable, the help lists the following interger assignment 0 - Disable, 1- Disable and Greyed, 2 Enable. If however, I right click on the generated Enum constant and select properties -> Edit Items, the listing order is as follows; 0- Enable, 1- Disable, 2- Disable and Greyed. The latter assignment is how the Enum constant actually works. It appears that the help information may be incorrect.
    Regards,
    Pat    
    Solved!
    Go to Solution.

    Hi,
    I compared it with 8.2.
    In 8.2 creating a constant, indicator or control by right clicking on the "disabled" property node gave an object of type U8, which operates in accordance with the "help for disabled", ie
    0=Enable
    1=Disable
    2=Disable/grey
    In 9.0/2009 right clicking and creating on the property node gives an Enum (of datatype U8) with names/values in agreement with 8.2, and operation as in 8.2, BUT the "help for disabled" message says
    0=Disable
    1=Disable/grey
    2=Enable
    Thus I would agree that this is a documentation error, and the LabVIEW is correct.
    N.I. Can we have a CAR please?
    P.S. I do think that it is a good idea to have made the disabled property an enum, whilst maintaining compatability with previous code. I always wondered why it wasn't that way in earlier revisions.

  • Use property nodes to change the state of a boolean through time

    I want to be able to switch the value from a boolean control, using property nodes, so that if the time elapsed is equal to 0,1 ,2 ,3 s, it should be false and if the time is equal o.5,1.5,2.5 s, the value should be true.
    Can some one tell me how to do this with propert nodes or with any other method?
    Thanks in advance!

    -Check this link for ideas on how to make loop run for specific period of time.
    http://forums.ni.com/t5/LabVIEW/how-to-make-a-loop-run-for-specific-period-of-time/td-p/1641018
    -To change value using property node>>right click boolean>>create>>Property node>>value>> Change it to write.
    -Forget about specific period of time, first learn to change the value of boolean programmatically.
    Thanks
    uday,
    Please Mark the solution as accepted if your problem is solved and help author by clicking on kudoes
    Certified LabVIEW Associate Developer (CLAD) Using LV13

  • Linking property nodes to two cursors in one graph

    Hello,
    I have got one graph with 2 cursors. And I need to by able to set the coordinates of each cursor by using property nodes. However, if I click right button mouse button - create - property node - cursor - cursor position - -then there are only 3 possibilities "All elements", "X", Y" which links only to one of the cursors (actually I don`t know which). How is possible to link 2 cursors`s position property nodes to 2 cursors in one graph?
     Thank you a lot for discussion.
    Martin Pekar
    Solved!
    Go to Solution.

    Also, if you have more than a few cursors, you can make the code more scalable by using an array of positions and a FOR loop as follows.
    Now the code automatically adapts th the number of cursors you actually have.
    (Of course all other common sense applies, for example only set this when the position changes. Don't write the same cursor postions with every iteration of the loop over and over. )
    Message Edited by altenbach on 05-06-2009 06:25 AM
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    MulticursorII.png ‏4 KB

  • I get error 1055 "Object Reference Is Invalid" when I try to write to a property node

    Hi, I'm trying to get these results to be displayed in two tables now, where I originally had them being displayed in just one. Outside of the attached vi, I can just copy the value property from one table to the other after this vi has run, and the table values appear properly. The problem with that is, that any table property I assign (changing background colours to be exact), is not considered part of the value property, and thus isn't copied when I copy the value from one to the other.
    The thing I can't understand is that the second set of property nodes (at the bottom), give me the "Object Reference Is Invalid" when I added them. I've tried everything I can think of, but can see no logical reason why I get that error for those two, while I don't get the error for the top two (not wired to constants).
    Any help on this would be much appreciated. Thanks
    Geoff
    Attachments:
    Table Display Testing.vi ‏396 KB

    The logical reason that you're getting that error is that you are not passing in a reference to Table In Two. The control is not wired to the connector pane so you are not getting a reference from the calling VI.

Maybe you are looking for

  • Duplicate File name check

    Hi,         I need to check whether the incoming file is already processed or not. The files are been placed on XI server. If the file with same file name comes then i dont want to process it. I am polling for files on xi server using file adapter. r

  • URGENT QUERY INFO NEEDED

    I HAVE A STANDARD SMART-FORM ME9K... I SHOULD DO CHANGES FOR THE SMART-FORM PLEASE HELP ME

  • Runtime.getRuntime().exec() Process question

    I saw a website to solve the "hang" of this. It says to use getInputStream() How come only get the Inpustream and not the OutputStream? Why is the output of a process that's executed now the InputStream?

  • Skype crashes on 7.2

    Hello, my problem is that Skype crashes when i try to call a friend or joining a group call, and after searching the forums, uninstalling and reinstalling skype, reseting the IE 11, skype still crashes. Below i attached my event viewer on the skype c

  • Transfer photos from macbook (Mac OS X 10.5.8) to IPhone5?

    How do I transfer photos from my macbook (Mac OS X 10.5.8) to my new Iphone5? I've got many photos in my macbook. Now that I've bought the iPhone 5 I can not sync it with my itunes on my macbook. I'm not able to download the new itunes version to my