Thread: Run-Time Error
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default Run-Time Error

Subscript out of range usually means that you have a typo in that array of
worksheet names.

CurtH wrote:

I get a run-time error '9': Subscript out of range.

Code:

ActiveWindow.DisplayWorkbookTabs = True
Sheets("UNIT BREAKOUT DATA").Visible = True
Sheets("UNIT BREAKOUT DATA").Select
Sheets("UNIT BREAKOUT DATA").Move Befo=Sheets(1)
ActiveWindow.ScrollWorkbookTabs Position:=xlLast
****Sheets(Array("FFD", "PEND", "COVER", "PROFILE SUMMARY CHART (WING)", _
"NOT RECONCILED RATE {BY MONTH}", "WING PROFILES BY MONTH", "MIL Due
Overdue", "CIV Due Overdue", _
"IMR Red", "HELP", "AF 422", "Compliance", "FFD", "ABBREV",
"UsageLog", "PEND", "READINESS TYPES", _
"IMMUNIZATIONS", "DEMOGRAPHICS-AF 422", _
"4T Profile", "INTRO", "MR DATA")).Select**********
ActiveWindow.SelectedSheets.Visible = False
Sheets("UNIT BREAKOUT DATA").Activate

Debug is highlighting the code between **********
**********

This code was working fine, but just blowup.


--

Dave Peterson