Application.Close

N

N1KO

Hi,

I have this simple bit of code in my close macro

ActiveWorkbook.Save
Application.Quit

When this runs it comes up with the "Do you want to save changes" dialog box
when i've already saved it automatically.

Is there anyway of getting rid of the Dialog Box?

Thanks in advance
 
J

Jacob Skaria

Try this//

ActiveWorkbook.Close Savechanges:=True
Application.Quit

If this post helps click Yes
 
N

Nigel

You might also consider using

ThisWorkBook.Save SaveChanges:=True

Ensuring the workbook being saved is the one with the code.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top