p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

vba_access thread: Link to Outlook


Message #1 by "robert mccafferty" <rmccafferty@e...> on Wed, 27 Dec 2000 16:53:49 -0000
Sure, here is the code you need....
______________________________________________________
Private Sub MailReport_Click()
On Error GoTo Err_MailReport_Click

    Const conErrCancel = 2501
    Dim stDocName As String

    stDocName = "Billing"
    DoCmd.SendObject acSendReport, stDocName, acFormatRTF, "Name of
Recipent", , , "Subject of Email"

    DoCmd.Close acForm, "Billing"

Exit_MailReport_Click:
    Exit Sub

Err_MailReport_Click:
    If Err.Number = conErrCancel Then
        MsgBox ("You chose to Cancel the option"), vbQuestion
    Else
        MsgBox Err.Description
        Resume Exit_MailReport_Click
    End If
End Sub
____________________________________________________________________________
______________________

Let me know if you need other information.

John




-----Original Message-----
From: robert mccafferty [mailto:rmccafferty@e...]
Sent: Wednesday, December 27, 2000 10:54 AM
To: VBA_Access
Subject: Link to Outlook


We have all seen Contact Us buttons on web sites that, when you click
them, open an email form already addressed to the host company.

In Access, is there any reasonable way that an email can automatically be
opened, addressed to the email address in the email field, in Outlook?
(Via a hyperlink field or a command button or any other method that is not
overly complicated?)


---
You are currently subscribed to vba_access as: $subst('Recip.EmailAddr')
To unsubscribe send a blank email to leave-vba_access-$subst('Recip.MemberIDChar')@p2p.wrox.com

  Return to Index