<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-15">
<META content="MSHTML 6.00.2900.3243" name=GENERATOR></HEAD>
<BODY style="MARGIN: 4px 4px 1px">
<DIV>Thanks Eric</DIV>
<DIV> </DIV>
<DIV>It turned out I had an error in the URL specifying the graphic icon. Fixing that solved the problem.</DIV>
<DIV> </DIV>
<DIV>Kind regards,</DIV>
<DIV> </DIV>
<DIV>Robert Sanson<BR><BR>>>> "Eric Lemoine" <eric.c2c@gmail.com> 16/09/2008 6:00 p.m. >>><BR>Hi.<BR><BR>I am not sure about what's causing you trouble. But, have you tried this:<BR><BR>new OpenLayers.Style(OpenLayers.Util.applyDefaults(your_style_object,<BR>OpenLayers.Feature.Vector.style["default"]));<BR><BR>In this way you make sure you have all the required properties.<BR><BR>Eric<BR><BR>2008/9/15, Robert Sanson <SansonR@asurequality.com>:<BR>> Here is how I specify a styleMap:<BR>><BR>> var style_gate = new OpenLayers.StyleMap({"default": new<BR>> OpenLayers.Style({<BR>> "graphicOpacity":1,<BR>> "externalGraphic":"markers/main_gate_16.gif",<BR>> "graphicXOffset":-8,<BR>> "graphicYOffset":-8,<BR>> "graphicWidth":16,<BR>> "graphicHeight":16,<BR>> "id":"main_gate",<BR>> "strokeLinecap":"round",<BR>> "strokeOpacity":1,<BR>> "fillOpacity":1,<BR>> "pointRadius":8})<BR>> });<BR>><BR>> I then reference this in my WFS layer definition:<BR>><BR>> var maingatewfs = new OpenLayers.Layer.WFS("Main Gate",<BR>><BR>> "http://10.65.192.1/cgi-bin/agbwfs.exe?farmid="+farmid+"&request=getfeature&typename=main_gates&service=wfs&version=1.0.0&BBOX="+x1+","+y1+","+x2+","+y2+"&maxfeatures=10<BR>> (<BR>> 'http://10.65.192.1/cgi-bin/agbwfs.exe?farmid="+farmid+"&amp;request=getfeature&amp;typename=main_gates&amp;service=wfs&amp;version=1.0.0&amp;BBOX="+x1+","+y1+","+x2+","+y2+"&amp;maxfeatures=10'<BR>> )",<BR>> {styleMap: style_gate, extractAttributes: true}<BR>> );<BR>> map.addLayer(maingatewfs);<BR>><BR>> However, I am still getting the standard translucent orange point symbol.<BR>><BR>> Can anyone point out what is wrong?<BR>><BR>> Many thanks,<BR>><BR>> Robert Sanson<BR>><BR>><BR>><BR>>>>> "Robert Sanson" <SansonR@asurequality.com> 15/09/2008 4:47 p.m. >>><BR>> I have a map with three WFS point lfeature ayers. I want to use different<BR>> markers for each WFS layer. How do I specify the icons to use?<BR>><BR>> Many thanks,<BR>><BR>> Robert Sanson<BR>> ------------------------------------------------------------------<BR>> The contents of this email are confidential to AsureQuality. If you have<BR>> received this communication in error please notify the sender immediately<BR>> and delete the message and any attachments. The opinions expressed in this<BR>> email are not necessarily those of AsureQuality. This message has been<BR>> scanned for known viruses before delivery. AsureQuality supports the<BR>> Unsolicited Electronic Messages Act 2007. If you do not wish to receive<BR>> similar communications in future, please notify the sender of this message.<BR>> ------------------------------------------------------------------<BR>><BR>><BR>> This message has been scanned for malware by SurfControl plc.<BR>> www.surfcontrol.com<BR>><BR>_______________________________________________<BR>Users mailing list<BR>Users@openlayers.org<BR><A href="http://openlayers.org/mailman/listinfo/users">http://openlayers.org/mailman/listinfo/users</A><BR><BR><BR><BR><BR></DIV><br><br><table bgcolor=white style="color:black"><tr><td><br>------------------------------------------------------------------<br>
The contents of this email are confidential to AsureQuality. If you have received this communication in error please notify the sender immediately and delete the message and any attachments. The opinions expressed in this email are not necessarily those of AsureQuality. This message has been scanned for known viruses before delivery. AsureQuality supports the Unsolicited Electronic Messages Act 2007. If you do not wish to receive similar communications in future, please notify the sender of this message.<br>
------------------------------------------------------------------</td></tr></table></BODY></HTML>