SendObject

Discussion in 'Access' started by James Petersen, Feb 10, 2018.

  1. James Petersen

    James Petersen

    Joined:
    Feb 10, 2018
    Messages:
    1
    Likes Received:
    0
    I use SendObject to send e-mail. If I refer to a field that's blank (e.g., EmailAddress), the e-mail isn't built (error). I tried using nz(field) but without success. Is there an easy fix for this?
     
    James Petersen, Feb 10, 2018
    #1
    1. Advertisements

  2. James Petersen

    HiTechCoach

    Joined:
    Dec 7, 2011
    Messages:
    16
    Likes Received:
    0
    It is Best Practice to first validate that the email exists before executing the sendobject.


    Psuedo code:

    If Nz(Me.MyEmailAddressControl,"") > "" Then

    Docmd. SendObject ...

    End If
     
    HiTechCoach, Nov 4, 2018
    #2
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.