le_vrai_homme
New Member
- Joined
- Nov 19, 2008
- Messages
- 12
I'm using a dictionary object with an item that contains an Array. In trying to set the value of array elements, it does not work. It simply stays with an Empty value. Any ideas? I don't seem to have problems setting the value of other non-array items in the dictionary.
Code:
Sub test()
Dim a() As Variant
ReDim a(1 To 10)
Set dict = CreateObject("scripting.dictionary")
With dict
.Item("Array") = a
.Item("Array")(1) = 0.4
MsgBox .Item("Array")(1)
End With
Set dict = Nothing
End Sub