View Single Post
  #7   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Claus Busch Claus Busch is offline
external usenet poster
 
Posts: 3,872
Default Close all without saving and exit without prompts

Hi Colin,

Am Sun, 17 Nov 2013 17:15:56 +0000 schrieb Colin Hayes:

I find it works fine for worksheets opened after the initial opening
sheet (book1), but still give prompts where any change in book1 or it's
macros has been made.


then try:

Sub Test()
Dim wbk As Workbook

For Each wbk In Workbooks
If wbk.Name < ThisWorkbook.Name Then
wbk.Close savechanges:=False
End If
Next
ThisWorkbook.Saved = True
Application.Quit
End Sub


Regards
Claus B.
--
Win XP PRof SP2 / Vista Ultimate SP2
Office 2003 SP2 /2007 Ultimate SP2