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
1070
XamDateTimeRangeSlider second thumb is always null
posted

I am trying to use the XamDateTimeRangeSlider in a similar way to the "Filtering ViewModel Data" example in the Samples application. I have the following XAML.

<ig:XamDateTimeRangeSlider x:Name="SliderDateRange"
        MinValue={Binding DateStart}"
        MaxValue={Binding DateEnd}"
        ThumValueChanged="SliderDateRange_ThumbValueChanged">

  <ig:XamDateTimeRangeSlider.TickMarks>
      .........
  </ig:XamDateTimeRangeSlider.TickMarks>

  <ig:XamDateTimeRangeSlider.Thumbs>
    <ig:XamSliderDateTimeThumb x:Name="dateTimeThumbStart" Value="{Binding DateStart}" />
    <ig:XamSliderDateTimeThumb x:Name="dateTimeThumbEnd" Value="{Binding DateEnd}" />
  </ig:XamDateTimeRangeSlider.Thumbs>

</igRibbon:XamDateTimeRangeSlider>

Here is the ThumValueChanged handler in the code-behind.
private void SliderDateRange_ThumbValueChanged(object sender, ThumbValueChagnedEventArgs<DateTime> e){

}

The dateTimeThumbStart works fine but dateTimeThumbEnd is always null. I know I do not need the Thumbs collection in the XAML but I tried it with and without without success. In the code-behind the this.SliderDateRange.Thumbs collection only ever has one item in the collection but I would think it would have two in this case.

I am trying to "bind" the XamDateTimeSlider to a XamDataChart, WPF DataGrid, and an XamPivotGrid. According to this example it just listens to the changing value of the thumbs in the code-behing and calls a Filter() method on the ViewModel. I do not see the ViewModel code in the example so my guess is that its altering the data-source for the other controls possibly using an ICollectionView. I was suprised there was no way to bind the XamDateTimeRangeSlider to the controls or possibly to the FlatDataSource.

Anyway...anyone know why I can not access the second thumb...why I only have 1 item in the Thumbs collection?

Thanks,

   -eric

Parents
  • 138253
    Offline posted

    Hello Eric,

     

    I am just checking the progress of this issue and was wondering if you managed to achieve your goal or if you need any further assistance on the matter.

Reply Children
No Data