Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Excel Spreadsheet - Mandatory fields
Is there a way to make an Excel spreadsheet not be able to close unless
certain fields are filled in? |
#2
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Excel Spreadsheet - Mandatory fields
You could put something in the BeforeClose event
Private Sub Workbook_BeforeClose(Cancel As Boolean) With Worksheets("Sheet1") If .Range("A1").Value = "" Then MsgBox "Value not supplied" Cancel = True End If End With 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 Phillips (remove nothere from email address if mailing direct) "Mike in Philly" <Mike in wrote in message ... Is there a way to make an Excel spreadsheet not be able to close unless certain fields are filled in? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
TRYING TO SET UP EXCEL SPREADSHEET ON MY COMPUTER | New Users to Excel | |||
windows explorer will not open an excel spreadsheet. | Excel Discussion (Misc queries) | |||
Excel Range Value issue (Excel 97 Vs Excel 2003) | Excel Discussion (Misc queries) | |||
How do I export an Excel spreadsheet to Pocket PC (Pocket Excel)?. | Excel Discussion (Misc queries) | |||
Copying an Excel spreadsheet to a Word document | Excel Discussion (Misc queries) |