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: 2
Default VBA how can I stop a Save

I would like to stop users from saving a workbook if a
cells contents have not been completed, I know that I can
use the Event BeforeSave to do a test on the contents of a
cell but how can I stop the save

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean,
Cancel As Boolean)
If Range("C10") = "" Then
MsgBox "Please complete cell C10"
Exit Sub
End If
End Sub

 
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
stop prompt to save on no changes made sam2u Excel Discussion (Misc queries) 1 June 2nd 08 09:07 PM
Stop prompting for save the changes in Excel dhardman Excel Discussion (Misc queries) 0 November 28th 07 05:11 PM
Save As - Can I use VBA? to stop XL Sheet overwrite Smudge Excel Discussion (Misc queries) 2 February 8th 07 01:12 AM
Stop asking to save changes Traci Excel Discussion (Misc queries) 3 October 11th 05 03:51 PM
How do I stop excel from asking me if I want to save my document? Jamie Setting up and Configuration of Excel 3 August 12th 05 03:24 AM


All times are GMT +1. The time now is 08:46 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"