Results 1 to 3 of 3

mutliple "beforesave" functions in same workbook

Threaded View

  1. #1
    Registered User
    Join Date
    10-16-2008
    Location
    St. Louis
    Posts
    6

    mutliple "beforesave" functions in same workbook

    ..again, thanks to this forum...great people....

    I have my VB code working great - spreadsheet now requires data entry in a specific cell and that requirement has been delayed until a certain date with a IF THEN statement. Thanks to all that helped!!

    I am now trying to broaden the "beforesave" requirement to multiple cells in the same workbook/worksheet. In the below VB statement, I don't know where to insert this additional command to require that a second cell have data entered into it before saving. The cell on the "Request for PTM" worksheet is H12.

    I would need a second message to appear relating to that specific cell as well; similiar to first message "Current Installed Irr. System Entry Required"

    
    Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
    If Date < #11/2/2008# Then Exit Sub
    If IsEmpty(Sheets("Request for PTM").Range("H11").Value) Then
    Sheets("Request for PTM").Activate
    Range("H11").Select
    MsgBox "Estimated Order Date Required"
    Cancel = True
      End If
    End Sub
    Thanks for all the great help!! You guys are awesome!!!
    Last edited by VBA Noob; 10-20-2008 at 03:27 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Macro moves out of Active WorkBook. Why?
    By ulfah in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-19-2008, 01:14 PM
  2. using cell content to reference a worksheet tab name in second workbook
    By Conor in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-29-2007, 09:32 AM
  3. Reference to a workbook
    By spreethi81 in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 08-28-2007, 01:23 PM
  4. Querying Data within an Excel Workbook
    By snowbob23 in forum Excel General
    Replies: 0
    Last Post: 02-21-2007, 05:48 AM
  5. '02 Excel Workbook to Workbook...HELP!!!
    By shutterlug in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-01-2007, 11:12 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1