LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

need a control

I have a ring control for fixed values of gain 1, 2, 5, 10 and time 0.1,
0.2, 0.5, 1, 2, 5, 10 sec.

How can I access instead of the enumerated value to the associated string or
the corresponding numeric value.

Peter Nyffeler mailto:nyffeler@phys.chem.ethz.ch
Tel P 01 363 62 42, Tel G 01 632 43 60, Fax G 01 632 10 21
0 Kudos
Message 1 of 4
(2,827 Views)
Peter;

To access the associated string, create a property node and read the String[] property, which is an array of the text items in the ring control. Use the current value of the ring to obtain the corresponding string.

Also, check "Create G enum from C enum statement numCtoG.vi" in Drolet's LabVIEW Bestiary. It can be what you need.

Regards;
Enrique

PD: Sometimes I think NI should consider a function to do something similar to what Drolet did in his numCtoG vi. It is very useful.
www.vartortech.com
0 Kudos
Message 2 of 4
(2,827 Views)
In article <5065000000050000005D7A0000-1021771306000@exchange.ni.com>, Enrique wrote:

Enrique,
Thank you for your answer.

>To access the associated string, create a property node and read the
>String[] property, which is an array of the text items in the
>ring control. Use the current value of the ring to obtain the
>corresponding string.

That is exactly what I was looking for.

May be you can help me on some other points.

1.a Is there a way to see the current value of all property nodes of an
object?

1.b By try and error I changed some properties by mistake.
Can they be reset to values as when taken from the controls palette?

2. On a chart I need increments other than 1 e.g 0.2.
Which the property node name
for scaling factor dX?

With best regards
Peter

Peter Nyffeler mailto:nyffeler@phys.chem.ethz.ch
Tel P 01 363 62 42, Tel G 01 632 43 60, Fax G 01 632 10 21
0 Kudos
Message 3 of 4
(2,827 Views)
May be this document also help you a little bit...

Creating a Text Ring Control for LabVIEW with Arbitrary Label/Value Pairs:
http://zone.ni.com/devzone/conceptd.nsf/webmain/A1825BF0A8BEB8CD862569B5000D0BB0?OpenDocument

You can see result in attached VI
0 Kudos
Message 4 of 4
(2,827 Views)