ArcObjects Library Reference (Geometry)  

ISpheroidEdit.Define Method

Defines the properties of a spheroid.

[Visual Basic .NET]
Public Sub Define ( _
    [ByRef Name As Object], _
    [ByRef Alias As Object], _
    [ByRef Abbreviation As Object], _
    [ByRef Remarks As Object], _
    [ByRef majorAxis As Object], _
    [ByRef Flattening As Object] _
)
[C#]
public void Define (
    ref object Name,
    ref object Alias,
    ref object Abbreviation,
    ref object Remarks,
    ref object majorAxis,
    ref object Flattening
);
[C#]

Optional Values

Name   To indicate that this parameter is undefined, first define a variable object Missing = Type.Missing; then pass this in as ref Missing.
Alias   To indicate that this parameter is undefined, first define a variable object Missing = Type.Missing; then pass this in as ref Missing.
Abbreviation   To indicate that this parameter is undefined, first define a variable object Missing = Type.Missing; then pass this in as ref Missing.
Remarks   To indicate that this parameter is undefined, first define a variable object Missing = Type.Missing; then pass this in as ref Missing.
majorAxis   To indicate that this parameter is undefined, first define a variable object Missing = Type.Missing; then pass this in as ref Missing.
Flattening   To indicate that this parameter is undefined, first define a variable object Missing = Type.Missing; then pass this in as ref Missing.
[C++]
HRESULT Define(
  VARIANT* Name,
  VARIANT* Alias,
  VARIANT* Abbreviation,
  VARIANT* Remarks,
  VARIANT* majorAxis,
  VARIANT* Flattening
);
[C++]

Parameters

Name [optional]   Name is a parameter of type VARIANT

  To indicate this parameter is undefined pass a reference to a VARIANT with type VT_ERROR and scode value of DISP_E_PARAMNOTFOUND.

Alias [optional]   Alias is a parameter of type VARIANT

  To indicate this parameter is undefined pass a reference to a VARIANT with type VT_ERROR and scode value of DISP_E_PARAMNOTFOUND.

Abbreviation [optional]   Abbreviation is a parameter of type VARIANT

  To indicate this parameter is undefined pass a reference to a VARIANT with type VT_ERROR and scode value of DISP_E_PARAMNOTFOUND.

Remarks [optional]   Remarks is a parameter of type VARIANT

  To indicate this parameter is undefined pass a reference to a VARIANT with type VT_ERROR and scode value of DISP_E_PARAMNOTFOUND.

majorAxis [optional]   majorAxis is a parameter of type VARIANT

  To indicate this parameter is undefined pass a reference to a VARIANT with type VT_ERROR and scode value of DISP_E_PARAMNOTFOUND.

Flattening [optional]   Flattening is a parameter of type VARIANT

  To indicate this parameter is undefined pass a reference to a VARIANT with type VT_ERROR and scode value of DISP_E_PARAMNOTFOUND.

Product Availability

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

Description

The majorAxis parameter represents the semimajor axis. For example, the semimajor axis of the WGS 1984 spheroid is 6378137.0 meters. The flattening value is a small number, such as 0.003352811 (WGS 1984). Often the inverse flattening value is used instead, 298.257223563, and that is what is reported in a well-known text (WKT) version of spheroid. The Define method expects the true flattening value.

[C#]     public ISpheroid DefineSpheroid()
    {            ISpheroid spheroid = new SpheroidClass();
        //cast interface to ISpheroidEdit            
        ISpheroidEdit spheroidEdit = spheroid as ISpheroidEdit;           
        //Define the properties of the spheroid            
        object name = "GRS_1980";           
        object alias = "GRS_1980";           
        object abbreviation = "GRS80";           
        object remarks = "Thespheroid is GRS_1980";           
        object majorAxis = 6378137; ;           
        object flattening = 1 / 298.257222101;           
        spheroidEdit.Define(ref name,                               
            ref alias,                               
            ref abbreviation,                               
            ref remarks,                               
            ref majorAxis,                               
            ref flattening                               
            );           
        return spheroidEdit as ISpheroid;       
    }

See Also

ISpheroidEdit Interface