Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
80
How to Display XamSliderNumericThumb Value?
posted

Hi,

I want to display XamSliderNumericThumb value (Not the TickMarks). How Can I do that?

<ig:XamNumericRangeSlider Grid.Row="0" Name="XamDateTimeRangeSlider1" MinValue="{Binding Path=VoltageRangeSlider.Min}" MaxValue="{Binding Path=VoltageRangeSlider.Max}">
<ig:XamNumericRangeSlider.TickMarks>
<ig:SliderTickMarks TickMarksFrequency="100" UseFrequency="True" />
<ig:SliderTickMarks TickMarksFrequency="100" UseFrequency="True" HorizontalTickMarksTemplate="{StaticResource HorizontalTick}"/>
</ig:XamNumericRangeSlider.TickMarks>
<ig:XamSliderNumericThumb Value="{Binding Path=VoltageRangeSlider.SafetyMin, Mode=TwoWay, NotifyOnSourceUpdated=True}" BorderBrush="Yellow" BorderThickness="10" Background="Brown" TrackFillBrush="Yellow" IsDragEnabled="False"/>
<ig:XamSliderNumericThumb Value="{Binding Path=VoltageRangeSlider.SafetyMax, Mode=TwoWay, NotifyOnSourceUpdated=True}" IsSnapToTickEnabled="True" />
<ig:XamSliderNumericThumb Value="{Binding Path=VoltageRangeSlider.Max, Mode=TwoWay, NotifyOnSourceUpdated=True}" BorderBrush="Red" BorderThickness="10" Background="Red" TrackFillBrush="Red" Visibility="Visible"/>
</ig:XamNumericRangeSlider>

Parents
No Data
Reply
  • 6759
    Offline posted

    Hi Kinsly,

    I assume you want to display the Thumb's value somewhere on/around the thumb so I would suggest you to use the thumb style and re-template the thumb and bind it's value.

    You could check out the following sample that is illustrating the approach(don't mind the Silverlight sample - the Control is basically the same in WPF but SL makes it a bit easier to share).

    Hope this helps. Let me know if I could be of more help on this matter.

Children
No Data