Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need Macro to close Excel? 1

Status
Not open for further replies.

cdove

MIS
Mar 20, 2002
153
GB
Can anyone let me have the code to add to the end of a macro which will automatically close excel?

TIA

Chris
 


Hi,
Code:
Application.Close


Skip,

[glasses] [red]Be Advised![/red]
The band of elderly oriental musicians, known as Ground Cover, is, in reality...
Asian Jasmine![tongue]
 
Code:
Excel.Application.Quit

If you want to prevent the "Do you want to save changes" dialog you will need to save the workbook first, or set the [tt]Saved[/tt] flag to [tt]True[/tt]
Code:
Workbook.Saved = [blue]True[/blue]

Hope this helps,
CMP

Instant programmer, just add coffee.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top