Thanks Dan, I'll have to give this a try. <br><br>I notice that your timer is going off every 10 minutes...how much data are you loading from the KML file? Is there much in the way of a noticeable flicker when you reload the layer (i.e. does all of the data completely disappear for a few seconds while the KML file is parsed and reloaded)? <br>
<br>I'd be looking to reload a layer containing between 20-100 text objects every 5 seconds or so and I'm not sure what the performance will be like under those conditions.<br><br>Cheers,<br><br>Andrew<br><br><div class="gmail_quote">
On Wed, May 13, 2009 at 1:35 AM, ChiefDan <span dir="ltr"><<a href="mailto:ChiefDan@gmail.com">ChiefDan@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
Andrew,<br>
Not sure if you found a solution, if not, this is what I've done.<br>
<br>
In the map init function, set a timer:<br>
<br>
window.setInterval(raingaugeRefreshData, 600000, rainGauges);<br>
<br>
Then in the timer service function:<br>
function raingaugeRefreshData(layer)<br>
{<br>
layer.loaded = false;<br>
layer.setVisibility(true);<br>
}<br>
By setting loaded to false then calling setVisibility(), openlayers goes and<br>
grabs the kml file again.<br>
<br>
Hope this helps.<br>
<br>
Dan<br>
<font color="#888888">--<br>
View this message in context: <a href="http://n2.nabble.com/KML-NetworkLink-and-auto-refresh-tp2531433p2870627.html" target="_blank">http://n2.nabble.com/KML-NetworkLink-and-auto-refresh-tp2531433p2870627.html</a><br>
Sent from the OpenLayers Users mailing list archive at Nabble.com.<br>
<br>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@openlayers.org">Users@openlayers.org</a><br>
<a href="http://openlayers.org/mailman/listinfo/users" target="_blank">http://openlayers.org/mailman/listinfo/users</a><br>
</font></blockquote></div><br>