Hi Team,
Getting TypeMismatch error while extracting dictionary items value into Cells.
Whats wrong here unable to identify. plz assist. Thanks
Thanks
mg
Getting TypeMismatch error while extracting dictionary items value into Cells.
Whats wrong here unable to identify. plz assist. Thanks
VBA Code:
Sub Dict()
Dim Dict As New Scripting.Dictionary
Dict.Add "Fruits", Array("Apple", "Banana", "Mango")
Cells(1, 1).Value = Dict.Item("FRUITS")(0)
Cells(1, 2).Value = Dict.Item("FRUITS")(1)
Cells(1, 3).Value = Dict.Item("FRUITS")(2)
End Sub
Thanks
mg