Thanks for the tip with dojo extent i will try it 🙂I added the code to the _measureAreaDblClickHandler function in the measurement.js of the jsapi.and //Bema�?ung Area hinzugefügt 28.06.2012
var xmuss = mapPoint.x - ((mapPoint.x - this.inputPoints[this.inputPoints.length-2].x)/2);
var ymuss = mapPoint.y - ((mapPoint.y - this.inputPoints[this.inputPoints.length-2].y)/2);
var winkelmuss = (Math.atan2((this.inputPoints[this.inputPoints.length-2].y - mapPoint.y), (this.inputPoints[this.inputPoints.length-2].x - mapPoint.x))*180)/Math.PI;
var pt = new esri.geometry.Point(xmuss, ymuss, this._map.spatialReference);
var textSymbol = new esri.symbol.TextSymbol();
textSymbol.setColor(new dojo.Color([0,0,0])).setFont(new esri.symbol.Font("12pt").setWeight(esri.symbol.Font.WEIGHT_BOLD));
// alert(this._geodesicDistance(this.inputPoints[this.inputPoints.length-2],mapPoint));
// alert(this._geodesicDistance(this.inputPoints[this.inputPoints.length-2],mapPoint)*0.0150605384943241495948941483426);
var gemessen = this._geodesicDistance(this.inputPoints[this.inputPoints.length-2],mapPoint)*1609.34;
//textSymbol.text = gemessen.toFixed(1) + "m";
textSymbol.text = dojo.number.format(gemessen.toFixed(1), {pattern: this.numberPattern}) + "m";
if(winkelmuss < 0 && winkelmuss > -90)
{
winkelmuss = winkelmuss*-1;
textSymbol.yoffset = -10;
textSymbol.xoffset = -10;
}else if(winkelmuss <= -90)
{
winkelmuss = (winkelmuss +180)*-1;
textSymbol.yoffset = 10;
textSymbol.xoffset = 10;
}else if(winkelmuss > 0 && winkelmuss < 90)
{
winkelmuss = winkelmuss*-1;
textSymbol.yoffset = -10;
textSymbol.xoffset = -10;
}else if(winkelmuss >= 90)
{
winkelmuss = (winkelmuss - 180)*-1;
textSymbol.yoffset = 10;
textSymbol.xoffset = 10;
}
textSymbol.angle = winkelmuss;
this.textGraphic=new esri.Graphic();
this.textGraphic.setSymbol(textSymbol);
this.textGraphic.setGeometry(pt);
this._map.graphics.add(this.textGraphic);
this.measureGraphics.push(this.textGraphic);
to the _measureAreaMouseClickHandler.Instead of the area i want to have the length of each path. Like this.[ATTACH=CONFIG]15690[/ATTACH]