AnsweredAssumed Answered

isSelfIntersecting for esri/dijit/Measure - always true

Question asked by mravichandran on Feb 6, 2017
Latest reply on Feb 7, 2017 by mravichandran

dear Readers,

 

thank you for taking the time to help me out.

 

We are using esri/dijit/Measure widget in our application - esri JS API 3.18.  

 

Our end users are predominantly ArcMap users for many many years and laying out specification for the web UI.  We are implementing a measurement feature using esri/dijit/Measurement in the application.  this measurement js tool allows users to draw self intersecting polygon and still computes the area. End users dont like the tool computing area for self intersecting polygons even though ArcMap allows measurement tool to draw a self intersecting polygon and computes the area.

 

 

there is a polygon.isSelfIntersecting flag and it always returns true even for simple triangle. 

 

geometry.isSelfIntersecting(geometry);
true
esri.geometry.polygonSelfIntersecting(geometry);
true
geometry.isSelfIntersecting()
true

 

I was planning to use this flag to raise an alert - looks like I am stuck.

 

thanks for your help.

 

regards

ravi.

Outcomes