close entire excel application


Posted by Sean Tobin on August 22, 2001 2:59 PM

Is there a way in a macro to close out of the entire application? Not just the active workbook but close out of excel entirely?

Posted by Barrett South London on August 22, 2001 3:18 PM

Sub Barretts_closexls()
'Dedicated to a wonderful specil trusted friend
'I dedicate all my scripts to friends, i miss
'you dearly 22.8.1 23.16GMT
For Each Barrett In Application.Workbooks
Barrett.Save
Next Barrett
Application.Quit

End sub

>>>> just closing is a bit pointless save all open xls as existiong flie names and kill xls ONLY

Good luck



Posted by Tom Urtis on August 22, 2001 4:57 PM


To quit Excel altogether:
Application.Quit