LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Slider buttons sense reversed

Solved!
Go to solution

In LabVIEW 8.5 I inserted a slider control onto my front panel, when I click the Up button it goes to the Top of my four position selection, then subsequent presses of the Up button cause it to go down.  Similarly, pressing Down takes the slide to the Bottom (if it is not already there), subsequent presses cause the slider to move up.

 

Why does the slide behave this way?  How can I change the behaviour to the intuitive Up for up and Down for down? 

0 Kudos
Message 1 of 24
(4,292 Views)

Can you attach a simple VI containing your control?

 

  • What are the "up/down buttons"??? (the triangles and the ends of a classic slide? The increment button of the digital display?)
  • What are the settings for data entry? (increment, max and min?
  • What is the datatype?
0 Kudos
Message 2 of 24
(4,284 Views)
Attached is the VI..  The button I call Up is the one that points up, the button I call Down is the one that points down.  These are the only buttons associated with a slider, call them what you may.
0 Kudos
Message 3 of 24
(4,278 Views)
(I am getting "unexpected error" every time I try to send the VI as an attachment.)  It is a basic vertical pointer slide with the up/down buttons w/value display.
0 Kudos
Message 4 of 24
(4,269 Views)
(If this one works, it means the discussion forum does not like Google Chrome,  VI attached.
0 Kudos
Message 5 of 24
(4,262 Views)

LabVIEW has about 20 different slides (modern, classic, system, etc.) and most (e.g modern) don't have up/down buttons, except on the digitial display (if visible). Thus my confusion.

 

Since the possible combinations of slide style, datatype, entry limits, and scale types are nealy infinite, a bit more detail is clearly needed so we can try to reproduce the problem. 😉

 

Your VI was not attached. can you try again. Thanks!

Message 6 of 24
(4,261 Views)

What are you trying to do? It's strange..

Message Edited by Pnt on 01-16-2009 08:46 PM
0 Kudos
Message 7 of 24
(4,259 Views)

It's an exercise is in LabVIEW for Everyone 3rd ed. so, of course, it is strange. I take the long view of wanting to know what a control does not function as expected.  

 

See calculator.vi above.  It posted after I switched from Chrome to IE 7. 

0 Kudos
Message 8 of 24
(4,249 Views)
Solution
Accepted by wildcatherder

Ah, text labels! You did not mention that! 😄

 

The up/down buttons for the digital display act according to the order in which they appear in the list (zero on top) so it is correct for that.

 

Solution: change the control properties and "invert" the scale. Now they match!

 

Also, change the datatype to integer (I32). You never want fractional values and then you also don't need to convert/coerce on the diagram.

 

(I am not sure about disabling the "wrapping around" when you reach the ends. Is this really a problem?)

Message 9 of 24
(4,247 Views)
Here's the correction (except for the wrapping around).
0 Kudos
Message 10 of 24
(4,242 Views)