Hello,
I dimensioned the variable Sht as a Worksheet. It should have been a Variant. Her eis the corrected code.
Sub SetHeightsAndWidths()
Dim MySheets As Variant
Dim Sht As Variant
MySheets = Array("FY09 Installation Support", "FY09 Install", "FY09 Purchase", _
"FY09 CF Discretionary Grants", "FY09 CF LOI", "FY08 Purchase", _
"FY08 Installation Support", "FY08 CF Discretionary Grants", _
"FY07 Sup Install Support", "FY07 CF Install Non-LOI", "FY07 Sup Purchase", _
"FY05 CF Carryover Install", "FY04 Recovery Funds", "FY05 Recovery Funds", _
"FY08 Safety Carryover", "FY09 Safety", "FY09 Transport Canada")
For Each Sht In MySheets
With Worksheets(Sht)
.Rows.RowHeight = 18#
.Columns.ColumnWidth = 12#
.Columns("A").ColumnWidth = 28#
.Columns("C").ColumnWidth = 28#
.Columns("T").ColumnWidth = 28#
End With
Next Sht
End Sub
Bookmarks