Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
When working on a document I clicked on the x to close the worksheet and I
got the usual dialogue and instead of clicking yes to save it I accidentally selected no. I know this question is far-fetched but I thought I would ask it anyway. Is there any Excel options that can be set to prompt you again. Thanks. |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean) Cancel = True Application.EnableEvents = False If MsgBox("Save the file", vbYesNo) = vbYes Then ThisWorkbook.Save Else If MsgBox("ARe you sure you don't want to save the file", vbYesNo) = vbNo Then ThisWorkbook.Save End If End If End Sub 'This is workbook event code. 'To input this code, right click on the Excel icon on the worksheet '(or next to the File menu if you maximise your workbooks), 'select View Code from the menu, and paste the code -- --- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "falcios" wrote in message ... When working on a document I clicked on the x to close the worksheet and I got the usual dialogue and instead of clicking yes to save it I accidentally selected no. I know this question is far-fetched but I thought I would ask it anyway. Is there any Excel options that can be set to prompt you again. Thanks. |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Re-enable events?
-- Jim "Bob Phillips" wrote in message ... | Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As | Boolean) | Cancel = True | Application.EnableEvents = False | If MsgBox("Save the file", vbYesNo) = vbYes Then | ThisWorkbook.Save | Else | If MsgBox("ARe you sure you don't want to save the file", vbYesNo) = | vbNo Then | ThisWorkbook.Save | End If | End If | | End Sub | | 'This is workbook event code. | 'To input this code, right click on the Excel icon on the worksheet | '(or next to the File menu if you maximise your workbooks), | 'select View Code from the menu, and paste the code | | | -- | --- | HTH | | Bob | | (there's no email, no snail mail, but somewhere should be gmail in my addy) | | | | "falcios" wrote in message | ... | When working on a document I clicked on the x to close the worksheet and I | got the usual dialogue and instead of clicking yes to save it I | accidentally | selected no. | | I know this question is far-fetched but I thought I would ask it anyway. | Is | there any Excel options that can be set to prompt you again. | | Thanks. | | |
#4
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Thank-you, it would be a good idea.
-- --- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Jim Rech" wrote in message ... Re-enable events? -- Jim "Bob Phillips" wrote in message ... | Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As | Boolean) | Cancel = True | Application.EnableEvents = False | If MsgBox("Save the file", vbYesNo) = vbYes Then | ThisWorkbook.Save | Else | If MsgBox("ARe you sure you don't want to save the file", vbYesNo) = | vbNo Then | ThisWorkbook.Save | End If | End If | | End Sub | | 'This is workbook event code. | 'To input this code, right click on the Excel icon on the worksheet | '(or next to the File menu if you maximise your workbooks), | 'select View Code from the menu, and paste the code | | | -- | --- | HTH | | Bob | | (there's no email, no snail mail, but somewhere should be gmail in my addy) | | | | "falcios" wrote in message | ... | When working on a document I clicked on the x to close the worksheet and I | got the usual dialogue and instead of clicking yes to save it I | accidentally | selected no. | | I know this question is far-fetched but I thought I would ask it anyway. | Is | there any Excel options that can be set to prompt you again. | | Thanks. | | |
#5
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
If you are asking if you can get your unsaved work back the answer is no.
Gord Dibben MS Excel MVP On Mon, 12 Feb 2007 02:46:01 -0800, falcios wrote: When working on a document I clicked on the x to close the worksheet and I got the usual dialogue and instead of clicking yes to save it I accidentally selected no. I know this question is far-fetched but I thought I would ask it anyway. Is there any Excel options that can be set to prompt you again. Thanks. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Excel file with hyperlinks takes a long time to open over the network | Links and Linking in Excel | |||
Weird File Open/Save As Behavior | Excel Discussion (Misc queries) | |||
Excel 2000 cannot save and create temp file | Setting up and Configuration of Excel | |||
Excel XP: File name in Title Bar not changed after Save As... | Excel Discussion (Misc queries) | |||
Can't save new excel file | Excel Discussion (Misc queries) |