Reinitializes the elements of arrays
Erase arraylist |
The required arraylist argument is one or more comma-delimited array variables to be erased.
Erase sets the elements of an array to Empty.
This example uses the Erase statement to reinitialize the elements of arrays.
' Declare array variables. Dim NumArray(10) As Integer ' Integer array. Dim StrVarArray(10) As String ' Variable-string array. Dim StrFixArray(10) As String * 10 ' Fixed-string array. Dim VarArray(10) As Variant ' Variant array. Erase NumArray ' Each element is set to Empty, which is equivalent to 0. |
See Also |
Dim Statement, ReDim Statement, Static Statement |