Purpose
Converts a MapBasic Coordinate System clause into an EPSG integer value for use with any MapBasic function or statement. You can call this function from the MapBasic window in MapInfo Pro.
Syntax
CoordSysStringToEPSG ( coordsys_string )
coordsys_string is a MapBasic CoordSys clause. EPSG (European Petroleum Survey Group) value is an integer value; for example, CoordSys Clause of "Earth Projection 1, 104" will return an EPSG code of 4326. For a complete list of EPSG codes used with MapInfo Pro see the MAPINFOW.PRJ file in your MapInfo Pro installation. The EPSG codes are identified by a "\p" followed by a number.
Return Value
Integer. If no EPSG value is found, it returns -1.
Description
The CoordSysStringToEPSG() function is used to convert a MapBasic CoordSys clause into an integer EPSG value.
Example
The following example displays EPSG code Earth Projection 1, 104 Coordinate System.
print CoordSysStringToEPSG("Earth Projection 1, 104")
See Also: