Maptitude GISDK Help

ArrayElementToReal(), A2R()

Summary

Converts an array element to a real number.

 

Syntax

int_value = ArrayElementToReal(array arr, int pos)

 

Argument Contents
arr An array
pos The position of the array element

 

Returns

The array element in the position pos if it is of the right type or null if the element is the wrong type or if pos is out of bounds.

 

Notes

Examples

// Get the X value returned by MapCoordToXY(), based on Longitude and Latitude fields

x = A2R(MapCoordToXY(, Coord(Longitude, Latitude)), 1)

 

opts = {{"Color", ColorRGB(0,0,0)}, {"Line Width", 4.5}, {"Names", "Fred", "Sam"}}

// To get the line width:

linewidth = A2R(FindOptionValue(opts, "Line Width"),1)

// linewidth is now equal to 4.5

 

See Also

Function Summary
ArrayElementToInteger() Converts an array element to an integer
ArrayElementToString() Converts an array element to a string
ExtractArray() Returns the specified sub-array, which must itself be an array

 

 

©2025 Caliper Corporation www.caliper.com