Unit 'amigados' Package
[Overview][Constants][Types][Procedures and functions][Index] [#amunits]

SetVar

Sets a local or environment variable

Declaration

Source position: amigados.pas line 1722

function SetVar(

  const name: pCHAR;

  buffer: pCHAR;

  size: LongInt;

  flags: LongInt

):LongBool;

function SetVar(

  const name: string;

  buffer: pCHAR;

  size: LongInt;

  flags: LongInt

):Boolean;

Arguments

name

  

pointer to an variable name. Note variable names follow filesystem syntax and semantics.

buffer

  

a user allocated area which contains a string that is the value to be associated with this variable.

size

  

combination of type of var to set (low 8 bits), and flags to control the behavior of this routine.

Function result

If non-zero, the variable was sucessfully set, False indicates failure.

Arguments

name

  

pointer to an variable name. Note variable names follow filesystem syntax and semantics.

buffer

  

a user allocated area which contains a string that is the value to be associated with this variable.

size

  

combination of type of var to set (low 8 bits), and flags to control the behavior of this routine.

Description

Sets a local or environment variable. It is advised to only use ASCII strings inside variables, but not required.

GVF_LOCAL_ONLY
set a local (to your process) variable.
GVF_GLOBAL_ONLY
set a global environment variable.

The default is to set a local environment variable.

See also

GetVar

  

Returns the value of a local or global variable

DeleteVar

  

Deletes a local or environment variable

FindVar

  

Finds a local variable


Documentation generated on: 2021-07-30