Dim myDict
Set myDict = CreateObject("Scripting.Dictionary")
myDict.Add 1, CreateObject("Scripting.Dictionary")
myDict.Add 2, CreateObject("Scripting.Dictionary")
Here, we've created 2 keys in the first level of the myDict Dictionary object. Then, we paired each key with a new Dictionary object, essentially creating a second dimension. You can use code similar to the following to populate the second dimension of the Dictionary and output the values to the browser:
myDict(1).Add 1, "Element"
myDict(2)(1) = "K"
response.write myDict(1)(1) & "<br>"
response.write myDict.Item(2).Item(2) & "<br>"
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.