<!DOCTYPE html PUBLIC '-//W3C//DTD HTML 4.01 Transitional//EN'>
<html><head><meta http-equiv="Content-Type" content="text/html;charset=us-ascii">
<style>BODY{font:10pt Tahoma,Verdana,sans-serif} .MsoNormal{line-height:120%;margin:0}</style></head><body>
Try to pass the instantiated object into the array:<br><br> this.selectCtrl = new OpenLayers.Control.SelectFeature([this.vectorLayer, this.rseqVectorLayer],{});<br><br>Here this.vectorLayer and this.rseqVectorLayer are the instantiated objects of  OpenLayers.Layer.Vector. <br><br>Met vriendelijke groet,<br><br>Meine Toonen<br>B3Partners BV<br>Tel: 030 214 2083<br><blockquote style="padding-left: 5px; margin-left: 5px; border-left: #0000ff 2px solid; margin-right: 0px"><hr><b>From:</b> Horst Garstka [mailto:horst@hike.de]<br><b>To:</b> openlayers-users@lists.osgeo.org<br><b>Sent:</b> Wed, 13 Feb 2013 10:51:43 +0100<br><b>Subject:</b> [OpenLayers-Users] SelectFeature with multi-vector-layers<br><br>Hi OL-users,<br>
I'm a little bit frustrated. Reason is that I try now for some days to<br>
persuade the OpenLayers.Control.SelectFeature to work with an array of<br>
two vector layers. With one everything is fine. But when I put this<br>
layer name into []-brackets I'm not able to select the features of this<br>
vector layer anymore. Not to speak of two layer array.  I've already<br>
compared my script with the example 'select-feature-multilyer.html'. And<br>
I found no fault.<br>
<br>
Therefore my question to you. Does someone know if there's a known<br>
problem in combination with OL 2.12?<br>
<br>
<br>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.osgeo.org">Users@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/openlayers-users" target="_blank">http://lists.osgeo.org/mailman/listinfo/openlayers-users</a><br>
</blockquote><style>
</style>
</body></html>