Results 1 to 2 of 2
  1. #1
    3 Star Lounger
    Join Date
    Jan 2001
    Posts
    294
    Thanks
    0
    Thanked 0 Times in 0 Posts

    using do send object for 2 attachements (access 2003)

    Using the code below to email an attachment. I would like to somehow incorparate the code to include a second attachment to the same email. This is done via 2 emails now. One is an instrcutioanl letter the other is the report they messed up. Can this be done? Thanks..

    1st attachment
    DoCmd.SendObject acReport, "DidNotSendHDTicket_rpt", "HTML(*.html)", "", "", "", "Site Support group: Problem Report (PR) information", "Please open attached documents and review.", True, ""



    2nd attachment

    Dim stLinkCriteria As String
    stLinkCriteria = "EIRID=" & Chr(34) & Me("EIRID") & Chr(34)
    DoCmd.SendObject acReport, "PRReport", "RichTextFormat(*.rtf)", "", "", "", "Site CPR Attached", "If you have any questions please respond to this email. Thank You...", False, stLinkCriteria

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: using do send object for 2 attachements (access 2003)

    Unfortunately, DoCmd.SendObject can only be used to send one attachment. If you need to send two or more attachments, you must use Automation to control Outlook in VBA. If you search for Outlook Application Attachment in this forum, you'll find examples.

Posting Permissions

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