`I have Slider to show these values with equal distance between each tick marks. I tried to use TickMarksFrequency = 20 . But it seems you can not use negative values for this.
20.0, 8.0, 0.0, -5.0, -10.0,-15.0, -20.0, -30.0, -40.0, -60.0, -90.0, -128.0
Can any one help to achive this?
Hello Shreekant,
You should be able to set the negative value. I am afraid we dont have TickMarksFrequency property.
Here is the API for the XamNumericSlider:
https://es.infragistics.com/help/wpf/infragisticswpf.controls.editors.xamslider~infragistics.controls.editors.xamnumericslider_members
I would like to knowwhat property did you set off the slider , did you set min value to 0 may be ?
Please share your sample for further investigation.
Hello Divya,
Here is simple example i want to set
<ig:XamNumericSlider MinValue="-128" MaxValue="20">
<ig:XamNumericSlider.TickMarks> <ig:SliderTickMarks TickMarksFrequency="20"> <ig:SliderTickMarks.TickMarksValues> <system:Double>-5.1</system:Double> <system:Double>-15</system:Double> <system:Double>-25</system:Double> <system:Double>-35</system:Double> <system:Double>55</system:Double> <system:Double>5</system:Double> <system:Double>15</system:Double> <system:Double>25</system:Double> <system:Double>35</system:Double> <system:Double>45</system:Double> </ig:SliderTickMarks.TickMarksValues> </ig:SliderTickMarks> </ig:XamNumericSlider.TickMarks></ig:XamNumericSlider>
</ig:XamNumericSlider>
The list with the negative numbers will not show in slider if I use Tick Frequency.
I problem that I am facing to show equal distance tick marks for these values in slider.
The difference between -90 and -60 is 30 which shows more space but for -10 to -5 space between them show less.
Distance between values show proper if I use same list with positive numbers.
Hi Divya,
I have xnumeric slider with this design below and all the tick marks values are created from backend.
I want to show these values are equally spaced between each tick. Could you suggest how can i achive that. I have small change set to 0.1 Large Change set to 1.
The example that you showed does not shows the tick marks for negative values. I can see only 6 tick values which are positive tick values. I don't see negative tick values.
Hello,
you are saying " have small change set to 0.1 Large Change set to 1. " means , i believe you are saying you set MinValue to 0.1, if so then you wound be able to see negative values.
See my sample here again , i have 2 positive and 4 negative tickvalues and i can clearly see them with red color also by setting IncludeSliderEnds to true would show the tick for start and end also:
That is exactly what I was looking for, but the range that I have is -128 and 20, With the tick values mentioned. Those tick values should show me equally distance in the slider. The example that you provided has distance of 5 between each tick marks. But the example that I am having, the distance increases as you reach min value(tick values show as logarithamic range).
I discuss the matter with the developer and I believe you are able to set negative values. About your second requirement, NumericSlider is a linear numeric scale, setting the tick value to equal distance is something not possible in your scenario means when you pass the TickMarksValues.
If suppose you don’t pass the TickMarksValues and set the UseFrequency and TickMarksFrequency then all the ticks would be equal distance based on TickMarksFrequency value.
Thank you very much Divya for the detailed explaination. I appreciate your effort put on this thread to explain me the solution.