I'm trying to generate a collection of all the sheets in a workbook.
Sub collMaker()
Dim coll As Collection, ws As Worksheet, x As String
For i = 2 To Application.Sheets.count
x = Application.Sheets(i).name
coll.Add Item:=x, Key:=x
Next i
End Sub
I get a runtime error '91' on the coll.add
line.