Determine SpatialReference Boundaries

06-23-2020 02:03 AM
Occasional Contributor


I would like to determine if a geometry is within the boundaries of the spatial reference.  In my particular case, all of our layers use the same spatial reference.  The geometry can be a point, polyline or polygon and is already in US Survey Feet (the same as the spatial reference).

Right now I am getting the Domain property of the SpatialReference and checking to see if the point is within it's XMin/XMax and Ymin/YMax values.  I have both a standard if block as well as using GeometryEngine.Contains.  In 99.44% of cases they seem to always return true.  In some rare instances, they return false.

The IntelliSense for the property seems to indicate that a MapPointa may not be valid even if it falls within this range.

I'd like to determine this before attempting to create the feature.

Is this the right approach or is there an alternative I should be using?



0 Kudos
1 Reply
Esri Contributor

Hi Kris,

The domain extent is different than the valid area of a coordinate system. The domain extent is an arbitrary square used to delimit valid coordinates for a spatial reference system and determine their resolution. It is possible that the domain extent is larger than the usable area of a coordinate system (a UTM zone, for example).

I suspect that what you are looking for is the horizon. We plan to add a method to get the horizon in a near-term release. In the meantime, you can take a look at  for a possible workaround. 

I hope that helps. 



0 Kudos