Clear Method (Collection Object) 

Deletes all elements of a Visual Basic Collection object.


Public Sub Clear()

The Clear method empties the collection and resets its Count property to 0.

Dim customers As New Microsoft.VisualBasic.Collection()
' Insert code that adds customers to collection.
customers.Clear()

Namespace: Microsoft.VisualBasic

Module: Collection

Assembly: Visual Basic Runtime Library (in Microsoft.VisualBasic.dll)

Show: