Erase Statement

고정된 크기 배열에 대한 배열 요소의 내용을 지우고 가변 크기 배열에서 사용한 메모리를 해제합니다.

Syntax:

Erase syntax

Erase array1 [, array2 [,...]]

Parameters:

array list - A comma delimited list of arrays to be erased.

Example:

Sub Erase_Example
    a = Array(1,2,3) :  b= Array("z","y","x") : c=Array(a,b)
    Erase a, c(Ubound(c)) ' b and c(0) are unchanged
    Erase b, c(0) ' everything gets cleared
End Sub

Dim or ReDim statements

Array or DimArray functions

Lbound and Ubound functions

Please support us!