Language Reference Guide : 4. System Classes : ActiveField Class : UndeclareData Method
 
Share this page                  
UndeclareData Method
The UndeclareData method disassociates the named ActiveField from variables previously associated with the DeclareData method.
This method has the following syntax:
integer = ActiveField.UndeclareData()
The data object is freed if there are no other references to it. Fields declared by the compiler (that is, those created in the visual development environment with Variable Declared set to on) cannot be undeclared. After you undeclare a field, dynamic expressions referring to it are invalid.
If the method is successful, it returns ER_OK. If it is not successful, it returns a non-zero value. Descriptions of system constant values and their numeric equivalents are listed in Error Codes.
For a discussion of using the UndeclareData method, see the Programming Guide.