LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

slider control units properties

I am using a vertical pointer slide control as a simple op interface object.  I am making th  units label and the digital display of the control visible.  I have selected my control units as feet.  I have also noticed that the digital display has a units field with it also.  It is also initialized as feet.
 
I have another control which is a units selection control which is a combo box (string) that is directly wired to the slider control units.text property node.  The goal is that when I change this units box to m, in, cm, mi, etc that the slider control will adjust and display the resultant readouts and graphics to be of the new unit type.
 
This is not working.  The scales and graphics are not refelcting the value of the control when I do this.  I then had tried to change the value of the digital display[0] property's units.text field property also to the same unit out of the combo box.  It still does not work.
 
Anyone know how to do this or is this a bug with this specific type of control?
0 Kudos
Message 1 of 15
(5,524 Views)
ID,
I just made some edits to your program and was able to see the scale and the digital display unit label change. I'm using LabVIEW 7.1.1 and everything seemed to work. See the attached file that I edited and let me know if that doesn't work. Thanks.
0 Kudos
Message 2 of 15
(5,483 Views)
Chris, thanks for the info.  However, the primary are that I am referring to as being a problem is that the actual blue fill of the slide does not change as I change the units from m to ft on the slide object.  Any ideas?
0 Kudos
Message 3 of 15
(5,477 Views)
Hey id,
I made a few modifications to your program. I deleted the property nodes getting and setting the value of the slider. I did this because when you change the unit type in the digital display, the conversion takes place automatically. You can verify this by editing the text of the digital display manually while the program isn't running. You'll note the number changes as you switch from "m" to "ft". 
Therefore if you do a conversion of the value of the slider in addition to changing the unit label on the digital display, you wind up doing a double conversion. When the unit conversion takes place, the level of the slider won't change, but the scale will change so that the correct value is displayed in the slider. Take a look at the program and let me know what you think.
0 Kudos
Message 4 of 15
(5,458 Views)

Chris,

I am running LV 7.1.  When I change the units field of the code you just sent me, the blue fill of the graphic slider and the scale value do not change.  See attached.

 

 

0 Kudos
Message 5 of 15
(5,448 Views)
id,
So I hate to be the bearer of bad news.... but it looks like there's a bug. If you "Window Wash" your front panel, you'll see the scale values update. That is, if you run the program, change the scale, and then minimize and maximize the window you'll see the value update. I apologize for the problem and will submit a bug fix report so that this problem is addressed.
0 Kudos
Message 6 of 15
(5,424 Views)
Thanks for confirming the problem.  NI is as perplexed at this one as I was.  I still have no answer from them. I did find a similar conclusion as did you by simply toggling the visible property for the scale and it appeared to work. I have concluded now that NI needs to redraw their graphic upon a value being changed in a property node to the slider to update the display.
 
Thanks
Message 7 of 15
(5,413 Views)
Hye !

Well I didn't find this post before write my question on a recent post about the using of units process....

I would like to know if the units system has been improved in Labview 8.0..

In fact I post this french post and this english post  to know how to use control and scale with units
the conversion of units (english system <-> S.I. and others) will be very helpful.....

So I search a way to use the Labview units tables....


Julien
Conception Informatique et électronique
CNRS LCSR Web
Orléans la Source FRANCE
0 Kudos
Message 8 of 15
(5,314 Views)
Hi Julien,

The short answer to your question is that LabVIEW doesn't offer anything new in the matter of unit conversion. The "Build Unit String" editor has exactly the same funtionality as in 7.1 - but that fuctionality is quite impressive as it is.

The issue mentioned in this thread has not been resolved in LabVIEW 8 either though lots of other issues have been.
- Philip Courtois, Thinkbot Solutions

Thinkbot Solutions
0 Kudos
Message 9 of 15
(5,286 Views)
My last post about this subject :

here

Ecosmose_CNRS  a écrit:
Hi Julien,

Translate from a website : soory I haven't enough time for english version...thanksd to understand my behaviour ! regards

Following a discussion with the Ni services, the solution definitively remains to be programmed, dixit the malls which I received, the American R&D assure me that it is not possible of uitliser the conversion system of units of labview directly by this software...

in runtime, However by changing the label of the units of a value, conversion is automatically not made Labview...but  to be rigorous and quite simply so that the prog does not plant, it is necessary to use the same syntax of labview (origin of my problem) and to remain in the same field of measurement... (distance, weight, speed, etc...)

This solution seems being the best: By using these bonds (conversions are constantly the same ones but syntax must be exact below the bonds proposes the syn, tax of the units of labview!)




 tables of units of labview (bonds above) stored in a file one can reutiliser the tables in drop-down lists then by building the label of unit, one then applies the conversion included in labview.... into changing this etiquette, labview converts the value, thus 1 meter becomes 100 centimetre when one changes ' m' into ' cm'

 --------ATTENTION NOT TO MAKE the REVERSE, applied an already converted value then changed the unit... Good I work there and would provide soon one VI on the forum

 THANK YOU VERY MUCH A Benjamin Mavel of Ni France which provided me the bonds...and which called and exposed my problem to the Ni R&D

To be continued...
Julien
Conception Informatique et électronique
CNRS LCSR Web
Orléans la Source





Julien
Conception Informatique et électronique
CNRS LCSR Web
Orléans la Source FRANCE
0 Kudos
Message 10 of 15
(5,244 Views)