• Welcome to Jose's Read Only Forum 2023.
 

IDictionary.HashVal Property

Started by José Roca, July 13, 2008, 10:30:55 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

José Roca



The following example illustrates the use of the HashVal property.


#INCLUDE "windows.inc"
#INCLUDE "scrrun.inc"

DIM pDic AS IDictionary
DIM vKey AS VARIANT
DIM vItem AS VARIANT
DIM vHashVal AS VARIANT

' Create an instance of the Dictionaty object
pDic = NEWCOM "Scripting.Dictionary"
' Add some key/item pairs to the dictionary
vKey = "a" : vItem = "Athens"
pDic.Add vKey, vItem
vKey = "b" : vItem = "Belgrade"
pDic.Add vKey, vItem
vKey = "c" : vItem = "Cairo"
pDic.Add vKey, vItem
' Get the hash value of the "c" key
vKey = "c"
vHasVal = pDic.HashVal(vKey)