Finance

Charts

Statistics

Macros

Search

Closing the Excel Application In Excel VBA

The following procedure closes the entire Excel application:

Sub CloseApplication()
    Application.Quit
End Sub

Explanation:

  • The Quit() method of the Application object is called.
  • This method closes Excel completely, including all open workbooks, the Visual Basic Editor (VBE), and the Excel Help window.
  • If any workbook has unsaved changes, Excel will prompt the user to save those changes before closing, as shown in Figure 6.10.
0 0 votes
Évaluation de l'article
S’abonner
Notification pour
guest
0 Commentaires
Le plus ancien
Le plus récent Le plus populaire
Online comments
Show all comments
Facebook
Twitter
LinkedIn
WhatsApp
Email
Print
0
We’d love to hear your thoughts — please leave a commentx