Hello OpenLayers, I have a vector layer which I have added to a map. Then later I want to be able to obtain this vector layer using:
var layerName = 'Panoramio Photos'; var vectorLayer = map.getLayersByName(layerName)[0]; But this does not work :(. I know for sure that the layer itself works because I see it on my map. I need to be able to obtain it though so that I can further use it in my code. Please if anyone knows anything about vector layers not being accessible with this method, drop a hint. I have used this method before to obtain other map layer instances with no issues. If there is a similar method for vector layers, please let me know. Many thanks in advance, elshae -- View this message in context: http://osgeo-org.1803224.n2.nabble.com/Get-Vector-Layer-By-Name-tp5785095p5785095.html Sent from the OpenLayers Users mailing list archive at Nabble.com. _______________________________________________ Users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/openlayers-users
