title: Is it possible to add a dictionary to an array in Excel VBA?
body: <p>I'm trying to figure out if this is a possibility in terms of the capability of excel. Consider the following code in what I'm trying to do:</p>
  <pre><code>Dim some_text, split_text() As String
  Dim some_array_dict() As String 'This is the array to store the dictionaries
  Dim some_dict As Dictionary 'The dictionaries that I'll be storing in the array above
  
  ReDim some_array_dict(y) As String 'y is previously defined as an integer
  
  For i = 0 To y - 1
      Set some_dict = New Dictionary
  
      some_text = some_array(2, i)
      split_text = Split(some_text, &quot; &quot;)
      
      For j = 0 To UBound(split_text)
          some_dict.Add split_text(j), 1
      Next j
      
      some_array_dict(i) = some_dict 'Issue
      
      Debug.Print some_array_dict(i) 'For debugging purposes
  Next i
  </code></pre>
  <p>The following is the line of code that gives me the error:</p>
  <pre><code>some_array_dict(i) = some_dict
  </code></pre>
  <p>Can anyone help with this?</p>