Dictionary.Count Property (VB6) |
Syntax
dictionaryobject.Count
dictionaryobject
Use: Required
Data Type: Dictionary object
A reference to a Dictionary object.
Property Data Type
Long.
Description
A read-only property that returns the number of key/item pairs in a Dictionary object.
Rules at a Glance
Unlike a Collection object, the Dictionary object is always 0-based.
Example
The following code fragment shows how you can use the Count property:
Dim vArray As Variant vArray = DictObj.Items For i = 0 to DictObj.Count -1 Set oObj = vArray(i) Next
Get VB & VBA in a Nutshell: The Language now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.