Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 31
Default no updates prompt at opening and save changes at closing

I couldn't find anything in this regard on help menu, but if it is possible
in excel, I'd like to know if I can make a book which when closing shouldn't
ask for save changes or is it really not possible, I'd appreciate any replies
in this regard.

SHARIQ

thanks in advance
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 492
Default no updates prompt at opening and save changes at closing

Only with VBA,
Hit Ctrl an F11 to open the VB editor, double click 'This Workbook' and copy
and paste this code into it,

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
ThisWorkbook.Saved = True
End Sub

Bear in mind that if someone opens the workbook with macro's disabled they
can do as they wish. There are ways to overcome that too, but Excel
protection of all kinds is weak and can be easily circumvented.
Regards,
Alan.

"Shariq" wrote in message
...
I couldn't find anything in this regard on help menu, but if it is possible
in excel, I'd like to know if I can make a book which when closing
shouldn't
ask for save changes or is it really not possible, I'd appreciate any
replies
in this regard.

SHARIQ

thanks in advance



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default no updates prompt at opening and save changes at closing

Do you want the workbook to close and save or just close without saving?

This code will save the workbook with changes and no prompt.

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ActiveWorkbook.Save
End Sub

This wiill close with no save and no prompt.

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ThisWorkbook.Saved = True
End Sub


Gord Dibben MS Excel MVP

On Mon, 8 Jan 2007 16:30:01 -0800, Shariq
wrote:

I couldn't find anything in this regard on help menu, but if it is possible
in excel, I'd like to know if I can make a book which when closing shouldn't
ask for save changes or is it really not possible, I'd appreciate any replies
in this regard.

SHARIQ

thanks in advance


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 31
Default no updates prompt at opening and save changes at closing

Hi Alan!

Well, first of all I'd like to thank you, that you replied to my question,
but some how the result I was looking for hasen't been achieved, or may be my
question wasen't clear enough, so if you care to answer to my question once
again please,

the question is.
When I close only this certain workbook it should'nt ask for save changes
but just closes its not important if changes made in the book are saved or
not (like for instance automatically) or so, so what you told about VBA
system, SO may be I didn't understand what it is, because I pressed CTRL +
F11 by doing so a new sheet got added to the book a macro 1 I copied and
pasted what you had suggested but it didn't work, so please can yu educate
me on this as how to do it properly,

thanx
Shariq

"Alan" wrote:

Only with VBA,
Hit Ctrl an F11 to open the VB editor, double click 'This Workbook' and copy
and paste this code into it,

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
ThisWorkbook.Saved = True
End Sub

Bear in mind that if someone opens the workbook with macro's disabled they
can do as they wish. There are ways to overcome that too, but Excel
protection of all kinds is weak and can be easily circumvented.
Regards,
Alan.

"Shariq" wrote in message
...
I couldn't find anything in this regard on help menu, but if it is possible
in excel, I'd like to know if I can make a book which when closing
shouldn't
ask for save changes or is it really not possible, I'd appreciate any
replies
in this regard.

SHARIQ

thanks in advance




Reply
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
Is it possible to diable save change at closing the workbook Shariq Excel Discussion (Misc queries) 1 December 23rd 06 02:06 PM
How do I save personal menu bar settings when closing program othf1993 Setting up and Configuration of Excel 0 August 19th 06 08:41 AM
Save Changes Prompt ExcelQuestion Excel Worksheet Functions 4 June 20th 06 11:25 PM
how to disable save prompt on closing excel file in automated mode [email protected] Excel Discussion (Misc queries) 3 July 6th 05 10:35 PM
Save prompt for Excel 2003 Adrastos Setting up and Configuration of Excel 1 February 6th 05 07:54 PM


All times are GMT +1. The time now is 08:56 AM.

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

About Us

"It's about Microsoft Excel"