Greetings,<br><br>Yes, it is possible to do this. After you create the ArcIMS layer, set up the mouse click event to call something like:<br><br>function mapclick( e ){<br> layer.getFeatureInfo( openlayers_map.getLonLatFromPixel( e.xy ), layer.options.layers[0], <br>
{<br> callback: clickresult,<br> scope: window<br> }<br> );<br> }<br>};<br><br>function clickresult(features){<br> if ( features !== null ) {<br> vector.addFeatures( features.feature );<br>
}<br>};<br><br>Where "layer" is your arcims layer, "layer.options.layers[0]" is a layer definition ArcXML needs a layer to query. In the callback, "features" is an object that corresponds to the ArcXML "FEATURES" element, and "vector" is your vector layer where you want your features. There is no need to manually parse the response, it is handled before the getFeatureInfo callback is invoked.<br>
<br>Just to let you know, there is a 1 map unit buffer by default. This may not be desireable, especially if you are working in EPSG:4326 (a 1 degree buffer may be massively huge).<br><br>Zwarg<br><br><div class="gmail_quote">
On Tue, Sep 15, 2009 at 6:20 AM, Jbaklouti <span dir="ltr"><<a href="mailto:jean-sebastien.baklouti@atosorigin.com">jean-sebastien.baklouti@atosorigin.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>
Hello,<br>
<br>
i see your implementation of arcxml format and arcims layer, that work's<br>
very well.<br>
I would like to know if that is possible to display vector layer from<br>
arcxml.<br>
It will work like wfs:<br>
- do arcxml request's (getfeature)<br>
- parse xml response<br>
- display vector from parsing.<br>
Are there an easy way to do it?<br>
<br>
Best regards<br>
<font color="#888888"><br>
--<br>
View this message in context: <a href="http://n2.nabble.com/Vector-layer-with-ArcXML-tp3648072p3648072.html" target="_blank">http://n2.nabble.com/Vector-layer-with-ArcXML-tp3648072p3648072.html</a><br>
Sent from the OpenLayers Users mailing list archive at Nabble.com.<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>