Unexpected results from typename
问题 I am getting some unexpected results from typename and am stumped. Hopefully some can point me in the right direction. Private Sub T() Dim d As Word.Document Dim s As String Dim c As Collection Dim i As Long Dim o As Object Set d = ActiveDocument s = "X" Set c = New Collection Debug.Print "d is a " & TypeName(d) Debug.Print "s is a " & TypeName(s) Debug.Print "c is a " & TypeName(c) c.Add (d) c.Add (s) For i = 1 To c.count Debug.Print "Item " & i & " of the collection is a " & " " & TypeName