LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 16
Default Disable save/saveas dialog box upon closing

I saw another topic on this where the user wanted to automatically
save. I have macros running that disable saving and want the dialog
box not to automatically pop-up as the save button on it doesn't work
anyway.

I was trying all kinds of code such as:

Sub Auto_Close()
WorkbookObject.Saved = True
WorkbookObject.Close
End Sub

I also tried:
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
Cancel = True
End Sub


Still, when I close the application, I get the box asking if I would
like to save changes. How do I keep this box from automatically
popping up? I searched other answers and saw that they recommended
code that automatically saved it, but that is different. I thought I
would be able to simply adjust the code, but I couldn't figure that
out.

Also, I am using ThisWorkbook as I imagine that is the right place for
such code. Please correct me if I am wrong. Thank you.
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How can just opening & closing a workbook prompt the Save? dialog? [email protected] Excel Programming 4 May 26th 08 08:40 PM
disable save as dialog box Dion Excel Programming 2 October 5th 06 09:11 PM
disable save and saveas from menubar and save via command button Steve E Excel Programming 5 September 13th 06 11:51 PM
closing read-only without save dialog box appearing JNW Excel Programming 0 December 28th 05 03:14 PM
Disable Saveas Dialog Tom Ogilvy Excel Programming 0 September 15th 04 05:41 PM


All times are GMT +1. The time now is 05:39 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"