Results 1 to 2 of 2

Thread: Emailing (2000)

  1. #1
    Star Lounger
    Join Date
    Oct 2003
    Thanked 0 Times in 0 Posts

    Emailing (2000)

    I know there have been posts regarding this subject before and I have spent an hour searching for one that could solve my problem but to no avail. I have a text box bound to the customer's email address. By double clicking, I want to start an email to that person. For my last attempt, my code is:

    Private Sub EMAIL_ADDRESS_DblClick(Cancel As Integer)
    Dim EmailAddress As String
    EmailAddress = Me.EMAIL_ADDRESS
    Application.FollowHyperlink "mailto:EmailAddress&subject=this is subject&body=this is body"
    End Sub

    Which produces the following result: See attachment.

    Anyhelp getting the To: address populated would be greatly appreciated.

    Attached Images Attached Images

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Thanked 31 Times in 31 Posts

    Re: Emailing (2000)

    Use this:

    Application.FollowHyperlink "mailto:" & EmailAddress & "&subject=this is subject&body=this is body"

    By keeping EmailAddress outside the quotes, the value of the variable is inserted instead of the name of the variable. You can also use this:

    DoCmd.SendObject acSendNoObject, , , EMailAddress, , , "This is the subject", "This is the body", True

Posting Permissions

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