Results 1 to 4 of 4
  1. #1
    nndatabase is offline Novice
    Windows XP Access 2007
    Join Date
    Jun 2013
    Posts
    4

    Send report individually by email address (DoCmd.SendObject)

    Can you help me please?
    I need to send the report using DoCmd.SendObject. However, I need to send it based on each tech's job via email.
    Currently all tech and jobs on the reports together. I need it to pull the email address and only send to that tech its jobs.
    Currently I'm using the basic vba code

    DoCmd.SendObject acSendReport, "R_DispatchInspectors", acFormatPDF, "email@me.com", , , "Job number", "Please see attached", False

    However do I allows this to send individual report connected to email address. (Which will have each tech's specific jobs sent to them only).
    FYI:
    table name: Inspectors (this one have their email address)


    Table name: JObs
    Report name: R_DispatchInspectors

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    See if this gets you started:

    Emailing a different report to each recipient
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    nndatabase is offline Novice
    Windows XP Access 2007
    Join Date
    Jun 2013
    Posts
    4
    Hi Pbaldy,
    Yes this gets me started. However I'm not that skilled to read the VBA for the link.
    Can you help me?

    I really just need the code that allows me to pull the email address from the report in separate reports.
    Sort of a
    Where the Inspector's email = ID connected to the jobs. So that all job for that inspectors are included in one email.
    Is there a simple (equal to/ = to ) code?

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,931
    Along with Paul's suggestion about filtering report, example for sending individual emails https://www.accessforums.net/program...ses-37200.html
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 10
    Last Post: 03-26-2012, 08:17 PM
  2. SendObject and No Email Address
    By Tomfernandez1 in forum Forms
    Replies: 6
    Last Post: 10-06-2011, 05:15 PM
  3. VBA Send Email using DoCmd.SendObject
    By malamute20 in forum Programming
    Replies: 15
    Last Post: 10-05-2011, 12:44 PM
  4. Email sent via DoCmd.SendObject
    By silverback in forum Programming
    Replies: 0
    Last Post: 10-29-2009, 06:26 AM
  5. Replies: 1
    Last Post: 05-01-2009, 07:33 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums