Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I would like the following macro to shut down all open files including 1
hidden file and the shut down the Excel program. I have used this macro for many years in Excel 5. I am now upgrading to Excel 2002 where it doesn't work. Do you have any suggestions as to what the problem could be? Dim Index As Integer, Number As Integer, FinalNumber As Integer 'Index is a loop counter Number = Application.Workbooks.Count 'The Number of open Workbooks FinalNumber = Number - 1 'The 1 refers to the hidden file For Index = 1 To FinalNumber 'Place the Workbook names in an array ActiveWorkbook.Close saveChanges:=True Next Index Application.Quit Thanks, Roger |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
need help to update macro to office 2007 macro enabled workbook | Excel Discussion (Misc queries) | |||
Macro automatic update | Excel Discussion (Misc queries) | |||
capture DDE update value in VBA macro | Excel Discussion (Misc queries) | |||
dde link update in vba macro | Excel Programming | |||
Macro update | Excel Programming |