SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Evangelist CyberFuture's Avatar
    Join Date
    May 2001
    Location
    San Diego, CA
    Posts
    434
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Silly Access Form Question

    I have an Access form that sends an e-mail when submitted. I need to place the the the value of the Order ID field into the subject line of the e-mail.

    Does anybody know how to do this?

  2. #2
    Sultan of Ping jofa's Avatar
    Join Date
    Mar 2002
    Location
    SvÝ■jˇ­
    Posts
    4,080
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    SendObject method syntax:
    DoCmd.SendObject [objecttype][, objectname][, outputformat][, to][, cc][, bcc][, subject][, messagetext][, editmessage][, templatefile]

    Example:
    [vbs]
    Dim strRecipient As String
    Dim strSubject As String
    strRecipient = "xxx@xxx.com"
    Me.txtOrderID.SetFocus
    strSubject = Me.txtOrderID.Text
    DoCmd.SendObject _
    acSendForm, _
    "", _
    acFormatTXT, _
    strRecipient, _
    "", _
    "", _
    strSubject, _
    "", _
    True, _
    ""
    [/vbs]


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
  •