gre.get_value( key [, key2, ...] )
Get the value of a variable from the data manager. This function is a convenience
function on top of gre.get_data
that allows the value to be returned
directly to the caller instead of a single table return value. A nil is
returned for any values that do not match a key in the data manager.
Parameters:
key The key whose value should be extracted from the data manager.
Returns:
The value associated with the data manager entry for the key, or nil if no entry exists. If multiple
keys are specified, then multiple return values will be generated matching the argument order.
Example - Accessing Control Width:
function get_control_width( mapargs ) -- This will extract the width of the control 'my_control' -- on the layer 'my_layer' -- This is the same example as gre.get_data() local value = gre.get_value("my_layer.my_control.grd_width") print("The width of the control is " .. tostring(value)) end