Results 1 to 3 of 3

Thread: How do I tell the db to "do nothing?"

  1. #1
    Join Date
    May 2003
    Posts
    25

    How do I tell the db to "do nothing?"

    I have a scenario where if the difference in a records origination date and today's date is >1 and <4 then an automatic email is sent for that record.

    Unfortunately, this isn't covering the scenario where the difference is 1 (if the origination date = today's date).

    How do I tell the db to

    If dDate is =1 Then "do nothing"

    then go to the second statement which is

    If dDate is >1 and dDate is <4 Then
    Dim objOutlook As Outlook.Application
    Dim objEmail As Outlook.MailItem

    Set objOutlook = CreateObject("Outlook.application")
    Set objEmail = objOutlook.CreateItem(olMailItem)

    (etc.)

  2. #2
    Join Date
    Nov 2002
    Location
    New Jersey, USA
    Posts
    3,932
    You don't need
    If dDate is =1

    statement at all. Just use the second statement.

  3. #3
    Join Date
    Nov 2003
    Location
    texas
    Posts
    5
    If dDate is =1 exit sub else
    dim...

    that should take of both if statements you mention

Posting Permissions

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