Advance thanks to all.I developed one ESRI silverlight web based application for displaying the last position of vehicle on map. In my application one lastposition button available.When the client will click on this button one graphic will b added to the map which denoting the last position of vehicle.Now everything is working fine.Now my requirement is , How to auto refresh this last position location on map in each 2 minute interval without cliking the button?Please help me ASAPhere is my code Private Sub LnkLastPosition_Click(sender As Object, e As System.Windows.RoutedEventArgs) Handles LnkLastPosition.Click
LastPosition()
End Sub
Private Sub LastPositionFinalRunning(ByVal sender As Object, ByVal e As SelectLastPositionCompletedEventArgs)
If e.Result.Count > 0 Then
'Dim geometry1 As New Point(csys, rs("lon"), rs("lat"))
.............
Dim graphic As New Graphic() With
{
.Geometry = New MapPoint(Convert.ToDouble(gpsNMEASentence(4)), Convert.ToDouble(gpsNMEASentence(2))),
.Symbol = TryCast(LayoutRoot.Resources(colourstyle), Symbol)
}
graphic.Attributes.Add("STRHOTSPOT", strhotspot)
AddHandler graphic.MouseLeave, AddressOf Graphic_MouseLeave
AddHandler graphic.MouseEnter, AddressOf Graphic_MouseEnter
graphicsLayer.Graphics.Add(graphic)
Dispatcher.BeginInvoke(Sub() ZoomToResolution(MyMap, 0.00000220549302222, New MapPoint(Convert.ToDouble(gpsNMEASentence(4)), Convert.ToDouble(gpsNMEASentence(2)))))
MyMap.Visibility = Windows.Visibility.Visible
End If
end sub