LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Create Control From Reference

Solved!
Go to solution

Using the type parameter of the Terminal is the best way to get the type of a control. If you try to do something like "get the value of the control and then ask for the type of that", you run into problems with LV classes and refnum types where the type of the value might be a child class of the type of the control.

 

CreateFromType.png

Message 1 of 6
(3,547 Views)
Solution
Accepted by AristosQueue (NI)

This question is answered.

0 Kudos
Message 2 of 6
(3,546 Views)

 

Where do you get the two enum constants? If I right click on style to create a constant it gives me an integer and not an enum.

=====================
LabVIEW 2012


0 Kudos
Message 3 of 6
(3,531 Views)

Using the Create from Reference method seems easier:

 

 

Create_From_Ref_BD.png


___________________
Try to take over the world!
Message 4 of 6
(3,506 Views)

 


@SteveChandler wrote:

 

Where do you get the two enum constants? If I right click on style to create a constant it gives me an integer and not an enum.


What version of LV are you using? At some point, this turned from an integer to an enum.  I don't know what version, and since I wrote that code snippet using my dev build, it may be a version that hasn't released yet.

 

0 Kudos
Message 5 of 6
(3,473 Views)

 


Aristos Queue wrote:
What version of LV are you using? At some point, this turned from an integer to an enum.  I don't know what version, and since I wrote that code snippet using my dev build, it may be a version that hasn't released yet.

 


I am using 2010 SP1

 

=====================
LabVIEW 2012


0 Kudos
Message 6 of 6
(3,467 Views)