ade_projgetinfo

Land Desktop Development ARX CPP SDK

Up a level
ade_projgetinfo
 
 

Gets information about a projection system.

struct resbuf*

ade_projgetinfo(

char* cscode,

char* info_type);

Returns a piece of coordinate system information or NULL.

cscode Coordinate system code, eight characters.
info_type Information type; see Information Types below.

You must release the resbuf.

Information Types
description Description. For example, "World Geodetic System of 1984 Latitude/Longitude in Degrees".
projection Projection. For example, "Unity Conversion, produce/accept lat/longs".
datum Datum. For example, "North American Datum of 1927, Mean Values".

The following sample parses the resbuf returned by ade_projgetinfo() and prints the value for the specified option. Then it releases the resbuf, as required.

char* pszCategoryCode = "MO-W";
char* pszInfoType = "description";
pCoordSysRb = ade_projgetinfo(pszCategoryCode, pszInfoType);
struct resbuf* rb = pCoordSysRb;
while(pCoordSysRb != NULL) {
    acutPrintf(
        "\nThe following %s information is available for the %s coordinate system:\n\n\t%s"
        , pszInfoType, pszCategoryCode, pCoordSysRb->resval.rstring);
    pCoordSysRb = pCoordSysRb->rbnext;
}
acutRelRb(pCoordSysRb);