View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Don Guillett Don Guillett is offline
external usenet poster
 
Posts: 10,124
Default Is there a button to close multiple files simultaneously

I use this which usually behaves

Sub CLOSE_ALL()
Application.ScreenUpdating = False
Application.DisplayAlerts = False
For Each w In Application.Workbooks
If w.Name < ThisWorkbook.Name Then
w.Save
w.Close
End If
Next w
ThisWorkbook.Save
'line below leaves excel
Application.Quit
End Sub

--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Lothar" wrote in message
...
Is there a button in excel which I can use to close/save multiple files
(worksheets)simultaneously?