laptop and a wrench

Bug

Query results for polygon layer do not contain the spatial reference information for each point in the ring.

Last Published: August 25, 2014 ArcGIS Server (.NET)
Bug ID Number NIM052326
SubmittedDecember 24, 2009
Last ModifiedJune 5, 2024
Applies toArcGIS Server (.NET)
Version found1.1
Operating SystemWindows OS
Operating System Version2003
StatusWill Not Be Addressed

Additional Information

No Public Explanation

Workaround

To resolve this issue, you need to loop each point in the polygon rings and assign a spatial reference to it. The workaround works for the polygon with only one ring. If the polygon have multiple rings, the code doesn't work properly. There will be no errer, but return you empty buffer results.-------------------- ESRI.ArcGIS.Client.Geometry.Polygon polygon = new ESRI.ArcGIS.Client.Geometry.Polygon(); ESRI.ArcGIS.Client.Geometry.PointCollection pnts = new ESRI.ArcGIS.Client.Geometry.PointCollection(); ESRI.ArcGIS.Client.Geometry.Polygon selectedStatePolygon = (ESRI.ArcGIS.Client.Geometry.Polygon)selectedState.Geometry; int ringNm = selectedStatePolygon.Rings.Count; ObservableCollection<ESRI.ArcGIS.Client.Geometry.PointCollection> pointcoll = new ObservableCollection<ESRI.ArcGIS.Client.Geometry.PointCollection>(); for (int j = 0; j < ringNm; j++) { foreach (MapPoint pnt in selectedStatePolygon.Rings[j]) { pnt.SpatialReference = MyMap.SpatialReference; pnts.Add(pnt); } pointcoll.Add(pnts); } polygon.Rings = pointcoll; polygon.SpatialReference = MyMap.SpatialReference; Graphic graphic = new Graphic() { Symbol = CustomRainbowGradientFillSymbol, Geometry = polygon };

Steps to Reproduce

Bug ID: NIM052326

Software:

  • ArcGIS Server (.NET)

Get notified when the status of a bug changes

Download the Esri Support App

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options