Returns the value of a local or global variable
Source position: amigados.pas line 1660
function GetVar( |
const name: pCHAR; |
buffer: pCHAR; |
size: LongInt; |
flags: LongInt |
):LongInt; |
const name: string; |
buffer: pCHAR; |
size: LongInt; |
flags: LongInt |
):LongInt; |
name |
|
Pointer to a variable name. |
buffer |
|
A user allocated area which will be used to store the value associated with the variable. |
size |
|
Length of the buffer region in bytes. |
flags |
|
combination of type of var to get value of (low 8 bits), and flags to control the behavior of this routine. |
Size of environment variable. -1 indicates that the variable was not defined.
name |
|
Pointer to a variable name. |
buffer |
|
A user allocated area which will be used to store the value associated with the variable. |
size |
|
Length of the buffer region in bytes. |
flags |
|
combination of type of var to get value of (low 8 bits), and flags to control the behavior of this routine. |
Gets the value of a local or environment variable. It is advised to only use ASCII strings inside variables, but not required. This stops putting characters into the destination when a n is hit, unless GVF_BINARY_VAR is specified. (The n is not stored in the buffer.)
Currently defined flags include:
The default is to try to get a local variable first, then to try to get a global environment variable.
|
Sets a local or environment variable |
|
|
Deletes a local or environment variable |
|
|
Finds a local variable |