I have several sheets that need to have an application run, but only if it is not hidden.
This is what I currently have and the macro stops to debug when it the sheetX is hidden.
Sheet5.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet7.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet9.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet11.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet13.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet14.Select
ActiveWindow.SelectedSheets.Visible = False
ActiveWindow.SelectedSheets.Visible = False
Sheet1.Select
Range("C22").Select
Range("C8").Select
Please help. Thanks.
This is what I currently have and the macro stops to debug when it the sheetX is hidden.
Sheet5.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet7.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet9.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet11.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet13.Select
Application.Run _
"'Program Spend Statement - Master Template.xls'!RemoveAndClear"
Sheet14.Select
ActiveWindow.SelectedSheets.Visible = False
ActiveWindow.SelectedSheets.Visible = False
Sheet1.Select
Range("C22").Select
Range("C8").Select
Please help. Thanks.