This document is archived and information here might be outdated.  Recommended version.


IGeometry.SpatialReference Property (ArcObjects .NET 10.7 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Geometry > ESRI.ArcGIS.Geometry > Interfaces > IG > IGeometry Interface > IGeometry.SpatialReference Property
ArcGIS Developer Help

IGeometry.SpatialReference Property

The spatial reference associated with this geometry.

[Visual Basic .NET]
Public Property SpatialReference As ISpatialReference
[C#]
public ISpatialReference SpatialReference {get; set;}
[C++]
HRESULT get_SpatialReference(
  ISpatialReference** spatialRef
);
[C++]
HRESULT putref_SpatialReference(
  ISpatialReference* spatialRef
);
[C++]
Parameters
spatialRef [out, retval]

spatialRef is a parameter of type ISpatialReference** spatialRef
spatialRef is a parameter of type ISpatialReference*

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Description

Returns and sets the Spatial Reference in which the geometry exists. If the spatial reference has not been set the property will return an empty ISpatialReference instance.

See Also

IGeometry Interface

.NET Samples

Move a graphic along a path in ArcMap Create a custom raster type from the ground up for DMCII data Create custom move, rotate, and scale GeometricEffects within a single project Create custom move, rotate, and scale GeometricEffects within a single project Creating a toolbar of globe tools Creating a toolbar of globe tools Geoevents in a MapControl RSS weather GraphicTracker RSS weather layer RSS weather layer Reducing schematic nodes and computing a cumulative attribute via a schematic rule StreetMap routing Triangle graphic element