Something like this.
Sub test()
Dim e, s, dic As Object
Set dic = CreateObject("Scripting.Dictionary")
dic("Jack") = Array(CreateObject("Scripting.Dictionary"), 3)
For Each e In Array(Array("Paul", 5, "Black"), Array("Michael", 10, "Blue"))
dic("Jack")(0)(e(0)) = Array(CreateObject("Scripting.Dictionary"), e(1), e(2))
For Each s In Array(Array("Superman", "Figurine", 7), Array("Batman", "Car", 6))
dic("Jack")(0)(e(0))(0)(s(0)) = Array(e(1), e(2))
Next
Next
MsgBox dic("Jack")(0).exists("Michael"), , "Check if ""Jack"" has ""Michael"""
MsgBox dic("Jack")(0)("Michael")(0).exists("Astro Boy"), , "Check if ""Michael"" has ""Astro Boy"""
End Sub
Bookmarks