Explicitly releases an object from memory.

Syntax

<oRef>.release( )

<oRef>

An object reference to the object you want to release.

Property of

All form objects; all report objects except Band and StreamFrame.

Description

dBASE Plus manages memory and resources used by objects automatically. When there are no more variables or properties that reference an object and that object is not visible onscreen, the object is destroyed. Any components that are contained in the object, such as the components of a form, are also destroyed when the container is destroyed. Because of this automatic object management, there is usually no reason to call release( ).

release( ) explicitly releases an object from memory, returning true if successful. Any references that point to that object become invalid; attempting to use such a reference results in an error. If these references are tested with EMPTY( ), it returns true.

For example, you might want to get rid of a single component in a form. You could release( ) that component, but in most cases you could just as easily hide the component by setting its visible property to false.