This document is archived and information here might be outdated. Recommended version. |
ArcObjects namespaces > Geometry > ESRI.ArcGIS.Geometry > Interfaces > IG > IGeographicCoordinateSystem Interface > IGeographicCoordinateSystem.CoordinateUnit Property (ArcObjects .NET 10.4 SDK) |
The angular unit of this geographic coordinate system.
[Visual Basic .NET] Public ReadOnly Property CoordinateUnit As IAngularUnit
[C#] public IAngularUnit CoordinateUnit {get;}
[C++]
HRESULT get_CoordinateUnit(
IAngularUnit** CoordinateUnit
);
[C++]
Parameters CoordinateUnit [out, retval]
CoordinateUnit is a parameter of type IAngularUnit
private void PrintCoordinateUnit()
{
// use activator class with SpatialReferenceEnvironment singleton
Type factoryType=Type.GetTypeFromProgID("esriGeometry.SpatialReferenceEnvironment");
System.Object obj=Activator.CreateInstance(factoryType);
ISpatialReferenceFactory spatialReferenceFactory=obj as ISpatialReferenceFactory;
IGeographicCoordinateSystem geographicCoordinateSystem=spatialReferenceFactory.CreateGeographicCoordinateSystem((int)esriSRGeoCSType.esriSRGeoCS_WGS1984);
IAngularUnit coordinateUnit=geographicCoordinateSystem.CoordinateUnit;
System.Windows.Forms.MessageBox.Show(coordinateUnit.Name);
}