Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

How to prevent ni:SliderDouble ranges from editing by user

Solved!
Go to solution

Hi,

I have a slider in WPF/C#

<ni:SliderDouble Height="60" Name="updateRate" ValueChanged="OnUpdateRateValueChanged" Range="0.05,1" Value="0.05"  />

When application is running user can change min or max value of the range by clicking on the tick lable and editing the value.

Need a way to prevent/protect, make it not editable.

Thank you

Yuri

0 Kudos
Message 1 of 3
(3,277 Views)
Solution
Accepted by topic author yurianikin

Scale range editing is controlled by the InteractionModeproperty on the slider. To disable EditRange, you can assign a different set of flag values, such as InteractionMode="ArrowKeys,Drag,Snap,ScrollWheel".

~ Paul H
0 Kudos
Message 2 of 3
(3,273 Views)

Thanks! Working!

0 Kudos
Message 3 of 3
(3,270 Views)