Hi,
I'm using AutoRefreshOverlay.aspx in the CSharp 2010 Samples as a basis to adding autorefresh capability to my SimpleMarkerLayer.
The sample seems simple and when run it runs fine and provides the functionality that I require.
My setup is as follows
XP SP3
VS2010. Dot Net 4.0
IE7 and Chrome
IIS V5.1
Map Suite Web Edition 4.0.40.0
However when I add the following to my own project
private void CreateVehicleLayer1()
{
[Code snipped]
SimpleMarkerOverlay vehicleOverlay = new SimpleMarkerOverlay("Vehicles");
vehicleOverlay.IsVisibleInOverlaySwitcher = true;
vehicleOverlay.AutoRefreshInterval = TimeSpan.FromMilliseconds(20000);
vehicleOverlay.Tick += new EventHandler<eventargs>(vehicleOverlay_Tick);</eventargs>
}
void vehicleOverlay_Tick(object sender, EventArgs e)
{
SimpleMarkerOverlay markerOverlay = (SimpleMarkerOverlay)Map1.CustomOverlays["Vehicles"];
this.TestOverlayRefreshLabel.Text = "Refreshed at " + DateTime.Now.ToString();
}
I get the error below after the first 20 second refresh.
I have only one marker on the map at the minute
I'm using a SimpleMarkerOverlay at the minute while waiting for an issue with the InMarkerMemoryOverLay to be resolved.
gis.thinkgeo.com/Support/Dis...aspx#19033
Any idea as to what I have missed?
Rgds,
Liam