Re: [OpenLayers-Users] Find out about the geometrytype of a layer

2010-04-15 Thread Alexandre Dube
Barbara, It's going to be hard to support further without a small test case showing the problem. Could you create one and report back, please ? Here's a link you might be interested reading before creating your test case : http://docs.openlayers.org/help/minimize.html Kind regards, Alexandre

Re: [OpenLayers-Users] Find out about the geometrytype of a layer

2010-04-14 Thread Barbara Fiederer
Hi Alexandre, the error is here: line 513 of vector.js: !(feature.geometry instanceof this.geometryType)) { . "feature.geometry" is undefined, "this.geometryType" is OpenLayers.Geometry.MultiLineString When I check in line 488 of vector.js "addFeatures: function(features, options) { ..." t

Re: [OpenLayers-Users] Find out about the geometrytype of a layer

2010-04-14 Thread Alexandre Dube
Barbara, I'm not sure what's going on, but I see you're using OpenLayers compressed. Try switching to uncompressed version and set a breakpoint in Vector.js in the addFeatures method (I guess the error is there). Is the feature correctly set to MultiLineString before it's added ? Try to look i

Re: [OpenLayers-Users] Find out about the geometrytype of a layer

2010-04-14 Thread Barbara Fiederer
Hi Alexandre, I added "myLayer.addOptions({geometryType:"OpenLayers.Geometry.MultiLineString"});" to the Layer options. -> Control in firebug: property is set correctly In geoserver: the_geom = MultiLineString the Control ist defined as follows: var mydraw = new OpenLayers.Control.DrawFeature( l

Re: [OpenLayers-Users] Find out about the geometrytype of a layer

2010-04-13 Thread Alexandre Dube
Barbara, By default, you can add any kind of geometry type to your vector layer. If you want to limit its types of geometry supported, you could use the 'geometryType' property when creating your layer object, then use this property when you want to automatically set the right handler of yo

[OpenLayers-Users] Find out about the geometrytype of a layer

2010-04-13 Thread Barbara Fiederer
Hi, how can I find out about the geometrytype of a vector layer? Any ideas? And does the suggested method work, even if there aren't any features yet? I want to automatically set the right handler for a DrawFeature-Control.   Thanks for answering   Barbara     NEU: WEB.DE DSL für 19,99 EUR/mtl.