[OpenLayers-Users] Add layers to Select control

Andreas Hocevar ahocevar at opengeo.org
Tue Jan 10 09:17:12 EST 2012


Try

selectControl.setLayer((selectControl.layers||selectControl.layer).concat(newLayer));

where newLayer is the layer you want to add.

Andreas.

On Tue, Jan 10, 2012 at 2:42 PM, Tobias Reinicke <ramotswa at gmail.com> wrote:
> Hello All,
>
> Is there a way I can add a layer to the select control without
> overriding any existing layer (as selectControl.setLayer() would do?)
>
> Thanks
>
> Toby
> _______________________________________________
> Users mailing list
> Users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/openlayers-users



-- 
Andreas Hocevar
OpenGeo - http://opengeo.org/
Expert service straight from the developers.


More information about the Users mailing list