Please enable JavaScript to view this site.

thinBasic Help Manual

* * HELP & MANUAL PREMIUM PACK 4 DEMO VERSION * *

This documentation was styled with a demo skin from the Premium Pack 4 add-on for Help & Manual. The contents of the skin are encrypted and not configurable. You can only publish HM projects with this skin. You cannot edit it or change it.

This version is copyright and may only be used for local testing purposes. It may not be distributed.

Please purchase the full version of the Premium Pack to get the configurable skins and remove this notice. The package will also include the Toolbox configuration utility for Premium Pack skins.

 

Description

 

Set a scalar variable, Variant, User-Defined Type, individual array element (or an entire array) to zero or null/empty.  RESET does not deallocate the actual memory used (with the exception of dynamic string array data, which is automatically deallocated).

 

Syntax

 

RESET variable [, ...]

RESET array() [, ...]

RESET array(index) [, ...]

 

Returns

 

None

 

Parameters

 

Remarks

 

If variable is numeric, it is set to zero.

If variable is a dynamic string, it is set to null ("", an empty string).

If variable is an ASCIIZ string, all the bytes are set to nul ($NUL).

If variable is a fixed-length string all the bytes are set to spaces.

If variable is a User-Defined Type, all bytes in variable are set to $NUL, or CHR$(0).

If variable is a Variant, it is cleared and set to data type %VT_EMPTY.

 

If array() is numeric, all elements are set to zero; otherwise all elements are set to zero/null.

If an array index value is specified within the parentheses, just that array element is set to zero/null, as if it were a scalar (non-array) variable.

 

RESET also works with absolute variables (variables declared with DIM ... AT ... clause), following the same rules specified above.

 

Restrictions

 

See also

 

Dim

 

Examples

 

 

 

Created with Help+Manual 8 and styled with Premium Pack Version 4 © by EC Software