LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

limit for slide

Solved!
Go to solution

Hello

In my project i use slides. I want to show the user the middle section in green and the outer sections in red.

Something like that, but as a slide and with two red sections (left and right end) and no color in the middle:

Unbenannt.PNG

Additionally the sections should be variable because the working area changes dynamicly. So i need to link it with a parameter.

 

Im thankful for every advice!

 

Matthäus

0 Kudos
Message 1 of 5
(2,965 Views)
Solution
Accepted by topic author matti90

Add additional, hidden sliders at the color change locations, chage the fill option and move them programmatically according to the desired position. What have you tried so far?

Message 2 of 5
(2,926 Views)
Solution
Accepted by topic author matti90

When I first looked at this, I thought that there wasn't a built-in function of the slider controls to work like this.  After altenbach's response, I took a second look and realized that each slider itself has a fill options property (rather than the control as a whole), so you can in fact set your lower limit slider to "Fill to Minimum", your upper limit slider to "Fill to Maximum", and your actual slider to "No Fill".

 

Slider_With_Red_Regions__Annotated.PNG

 

Slider_With_Red_Regions.PNG

 

However, you then need to find a way to make the now-transparent sliders not movable by the user.



Message 3 of 5
(2,915 Views)

you can also change the colors in advance custom controls, thus only 1 control

Control 9.ctl_FP.png

0 Kudos
Message 4 of 5
(2,890 Views)

@VItan wrote:

However, you then need to find a way to make the now-transparent sliders not movable by the user.


I don't think the sliders can be disabled individually, but you could just filter them in an event structure and only accept the change of the middle slider.

0 Kudos
Message 5 of 5
(2,881 Views)