The Dictionary Object | |
The Dictionary object provides a useful storage object that we can use to store values, accessed and referenced by their name rather than by index as would be the case in a normal array. |
CompareMode | VBScript only |
Property | |
Sets or returns the string comparison mode for the keys. *An error will occur if we try to change the CompareMode of a Dictionary object that already contains data. |
Count | |
Property | |
Read only. Returns the number of key/item pairs in the Dictionary. |
Item(key) | |
Property | |
Sets or returns the value of the item for the specified key. |
Key(key) | |
Property | |
Sets or returns the value of a key. |
Add(key,item) | |
Method | |
Adds the key/item pair to the Dictionary. *An error will occur if we try to add a key/item pair when that key already exists. |
Exists(key) | |
Method | |
Returns True if the specified key exists or False if not. |
Items() | |
Method | |
Returns an array containing all the items in a Dictionary object. |
Keys() | |
Method | |
Returns an array containing all the keys in a Dictionary object. |
Remove(key) | |
Method | |
Removes a single key/item pair specified by key. *An error will occur if we try to remove a key/item pair that doesn't exist. |
RemoveAll() | |
Method | |
Removes all the key/item pairs. *An error will occur if we try to remove a key/item pair that doesn't exist. |