Hi,

I can't seem to figure out how to measure a vector layer.

My layer looks like this:

var vectorLayer = new OpenLayers.Layer.Vector("Line Vectors", {
                        styleMap : sm,
                        eventListeners : {
                                "featuresadded" : dataLoaded
                        },                        
                });
var polygon = new OpenLayers.Control.<b>DrawFeature</b>(vectorLayer, 
                                                OpenLayers.Handler.Polygon, {
                                                        displayClass : 'polyButton',
                                                        title : 'Add Polygon',
                                                        handlerOptions : {
                                                                style : sty
                                                        }
                                                });
editPanel.addControls([        polygon ]);

the example here: openlayers.org/dev/examples/measure.html

goes straight to this: 
new OpenLayers.Control.<b>Measure</b>(
                    OpenLayers.Handler.Path, {
                        persist: true,
                        handlerOptions: {
                            layerOptions: {styleMap: styleMap}
                        }
                    } 

How do I get this to work when I defined my polygon vector layer as a OpenLayers.Control.DrawFeature? Any help would be appreciated.  Thanks! Jonathan
        
<br/><hr align="left" width="300" />
View this message in context: <a href="http://osgeo-org.1803224.n2.nabble.com/Measure-a-Vector-layer-tp6289410p6289410.html">Measure a Vector layer?</a><br/>
Sent from the <a href="http://osgeo-org.1803224.n2.nabble.com/OpenLayers-Users-f1822463.html">OpenLayers Users mailing list archive</a> at Nabble.com.<br/>