KRASCHE
&
BYRNE
         ELZED  HOME       NEWS       DOCS       DOWNLOADS       LICENSING       SUPPORT       FAQ       ABOUT  US

What's An Elzed?
Features
Licensing
Downloads
Documentation
Elzed News
    ELZED 
 Documentation 
 The Details 
 API 

lzDeleteVar

The lzDeleteVar function destroys a previously defined variable.

long lzDeleteVar(
   char cScope,   // the scope of the variable
   const char* szVariableName   // the name of the variable
);

Parameters

cScope
   A character code indicating the scope of the target variable. The character code must be one of the following values:

Code
Constant
Meaning
'C'
kCosmicScope
Available in all contexts
'G'
kGlobalScope
Available in current context only


szVariableName
   A null-terminated character string containing the name of the target variable.

Return Value

   Returns an Elzed error code. If the variable is successfully deleted, returns "No Error". Returns a non-zero Elzed error code if not successful. Call lzGetLastErrorText to determine the reason for the failure.

Remarks

   The target variable must exist in the current context and/or at the specified scope. If the target is linked to a variable in your code, this call will break the link before destroying the target variable. The variable within your code will not be affected in any way by this call.

If the target variable is used by an expression created through lzParseExp, calls to delete the variable will fail. You must delete the expression via lzDeleteExp before deleting the target variable.

You may also use this call to delete Elzed arrays.

Versions

   Introduced in Elzed 1.2.0
Modified in Elzed 2.4.0 -- String (char*) parameter is now declared const.
   This page describes the version of lzDeleteVar active in Elzed 2.5.0 (189: 2.5.0)

See Also



  Copyright  ©  MMXXV  by  R R Le Cropane   •   All Rights Reserved   •   Terms of Use   •   Privacy Policy