AnsweredAssumed Answered

ESRI ArcGIS TimeSlider issue with multiple Feature Layers

Question asked by humzarr on Oct 28, 2013
Latest reply on Nov 5, 2013 by dlednik-esristaff
I am using ArcGIS API for WPF for my mapping application and my goal in this mapping application is to display time aware featurelayers and then use a TimeSlider (ESRI TimeSlider) to change the Time Extent of the layers. I am using the following two layers provided by ESRI.

I am using ESRI TimeSlider as follows.

     <esri:TimeSlider x:Name="GTTimeSlider" Grid.Row="2" Grid.Column="0" Grid.ColumnSpan="5"                              TimeMode="TimeExtent"                             MinimumValue="{Binding LayerTimeExtentStart,Mode=TwoWay}"                              MaximumValue="{Binding LayerTimeExtentEnd,Mode=TwoWay}"                              Value="{Binding LayerTimeExtent,Mode=TwoWay}"                             Intervals="{Binding LayerTimeIntervals, Mode=OneTime}" BorderBrush="White"                    Background="{x:Null}" >


The properties `LayerTimeExtent`, `LayerTimeExtentEnd` and `LayerTimeExtentStart` are set in the ViewModel for the `TimeSlider`. These values are initialized based on the TimeExtent of the feature layers which I mentioned above when they are added on the map. Using DataBinding I have bound these properties to the BaseMap using:

        Binding myBinding = new Binding("LayerTimeExtent");         myBinding.Source = this;         map.SetBinding(Map.TimeExtentProperty, myBinding);

The issue arises when I add both layers at the same time to the map. Although both layers initialize their own TimeSliders but changing the value of `TimeSlider` on one layer dialog box changes the `TimeExtent` value on the other layer as well as both are on the map at that moment and the map `TimeExtentProperty` is bound to the Value of `TimeSlider`. Is there a work around for this problem?

Here is a screenshot of the TimeSlider View along with the layers added on the basemap.