![]()  | 
                    
                         This document is archived and information here might be outdated. Recommended version.  | 
                
Creates a predefined geographic coordinate system.
[Visual Basic .NET] Public Function CreateGeographicCoordinateSystem ( _ ByVal gcsType As Integer _ ) As IGeographicCoordinateSystem
[C#] public IGeographicCoordinateSystem CreateGeographicCoordinateSystem ( int gcsType );
[C++]
HRESULT CreateGeographicCoordinateSystem(
  long gcsType
);
[C++] Parameters gcsType
gcsType is a parameter of type long
Use an element from the esriSRGeoCSType, esriSRGeoCS2Type, or esriSRGeoCS3Type enumerations as the gcsType to create a particular predefined geographic coordinate system.
The example code shows how to create an object that represents the WGS 1984 geographic coordinate system.
            ISpatialReferenceFactory spatialReferenceFactory = new SpatialReferenceEnvironmentClass();
            //Create a geographic coordinate system using the available geographic
            //coordinate systems. These can be found in the esriGeometry esriSRGeoCSType
            //enumeration.
            IGeographicCoordinateSystem geographicCoordinateSystem = spatialReferenceFactory.CreateGeographicCoordinateSystem((int)esriSRGeoCSType.esriSRGeoCS_WGS1984);
        Dim pSpatRefFact As ESRI.ArcGIS.Geometry.ISpatialReferenceFactory
        'Set the spatial reference factory to a new spatial reference environment
        pSpatRefFact = New ESRI.ArcGIS.Geometry.SpatialReferenceEnvironment
Dim pGCS As ESRI.ArcGIS.Geometry.IGeographicCoordinateSystem
        'Create a geographic coordinate system using the available geographic
        'coordinate systems. These can be found in the esriGeometry esriSRGeoCSType
        'enumeration.
        pGCS = pSpatRefFact.CreateGeographicCoordinateSystem(ESRI.ArcGIS.Geometry.esriSRGeoCSType.esriSRGeoCS_WGS1984)
ISpatialReferenceFactory Interface | esriSRGeoCSType Constants | esriSRGeoCS2Type Constants | esriSRGeoCS3Type Constants