<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content=text/html;charset=Windows-1252 http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 9.00.8112.16430"></HEAD>
<BODY style="PADDING-LEFT: 10px; PADDING-RIGHT: 10px; PADDING-TOP: 15px"
id=MailContainerBody leftMargin=0 topMargin=0 CanvasTabStop="true"
name="Compose message area">
<DIV><FONT size=2 face=Arial>Hello OpenLayers-Users!</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2 face=Arial>I have some trouble with displaying a
vector-layer on a map in Internet Explorer. In Chrome and Firefox, it works
without problems but in IE, there is nothing to see except the
OSM-map.</FONT></DIV>
<DIV><FONT size=2 face=Arial>The Layer-Switcher shows my map as well as the
vector-layer, but as i said there is nothing to see except the map.</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2 face=Arial>I found out, that some people had issues similar to
this and the problem was, that the code for the vector-layer or whatever was
processed too early, so they just needed to wait until body onload.</FONT></DIV>
<DIV><FONT size=2 face=Arial>But this seems to be NOT my problem, since
I call my createMap()-function in init(), which is called on
body-onload.</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2 face=Arial>IE is not giving me any error, so i also don't know
where to start. It's really annoying and I would be so glad, if you would have
any hints for me.</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2 face=Arial>Here's my code, let me know if you need
more.</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT> </DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2 face="Bitstream Vera Sans Mono">function
createMap(kmlDoc){</FONT></DIV>
<DIV><FONT face="Bitstream Vera Sans Mono"></FONT> </DIV>
<DIV><FONT size=2 face="Bitstream Vera Sans Mono"> map = new
OpenLayers.Map({<BR> div: "map",<BR> allOverlays:
true<BR> });<BR> var osm = new OpenLayers.Layer.OSM();</FONT></DIV>
<DIV><FONT size=2 face="Bitstream Vera Sans Mono"> map.addControl(new
OpenLayers.Control.LayerSwitcher());<BR> map.addControl(new
OpenLayers.Control.MousePosition());<BR> </FONT></DIV>
<DIV><FONT size=2 face="Bitstream Vera Sans Mono"> var defaultStyle = new
OpenLayers.Style({<BR> pointRadius: 4,</FONT></DIV>
<DIV><FONT size=2 face="Bitstream Vera Sans Mono"> fillColor:
"#ffcc66",<BR> strokeColor: "#ff9933",<BR> strokeWidth:
1,<BR> graphicZIndex: 1<BR> }); <BR> var selectStyle =
new OpenLayers.Style({<BR> pointRadius: 6,<BR> fillColor:
"#66ccff",<BR> strokeColor: "#3399ff",<BR> graphicZIndex:
2<BR> }); <BR> var myStyles = new
OpenLayers.StyleMap({<BR> "default":
defaultStyle,<BR> "select":
selectStyle<BR> });<BR> </FONT></DIV>
<DIV><FONT size=2 face="Bitstream Vera Sans Mono"> var features =
createMapFeatures(kmlDoc);</FONT></DIV>
<DIV><FONT face="Bitstream Vera Sans Mono"></FONT> </DIV>
<DIV><FONT size=2 face="Bitstream Vera Sans Mono"> var machineLayer = new
OpenLayers.Layer.Vector("Points", {<BR> styleMap:
myStyles,<BR> rendererOptions: {zIndexing:
true}<BR> });<BR> machineLayer.addFeatures(features);<BR> <BR> map.addLayers([osm,
machineLayer]);</FONT></DIV>
<DIV><FONT face="Bitstream Vera Sans Mono"></FONT> </DIV>
<DIV><FONT size=2 face="Bitstream Vera Sans Mono"> select = new
OpenLayers.Control.SelectFeature(machineLayer);<BR> machineLayer.events.on({<BR> "featureselected":
onFeatureSelect,<BR> "featureunselected":
onFeatureUnselect<BR> });<BR> map.addControl(select);<BR> select.activate(); </FONT></DIV>
<DIV><FONT size=2 face="Bitstream Vera Sans Mono"> </FONT></DIV>
<DIV><FONT face="Bitstream Vera Sans Mono"><FONT size=2> suisseBounds = new
OpenLayers.Bounds(662556, 5751427, 1171817, 6076781);</FONT></FONT></DIV>
<DIV><FONT size=2
face="Bitstream Vera Sans Mono"> map.zoomToExtent(suisseBounds,
false);<BR>}<BR></FONT></DIV></BODY></HTML>