I currently have the following VB code in a MS Access Database which I use
to send emails. Nonetheless, it opens Outlook and I would like it to send an
email using Outlook Express. Could anyone please oblige in ammending the
code for me, so that it uses Outlook Express 5?
Thanks
______________
Private Sub cmdSendEmail_Cl ick()
Dim objOutlook As Express.Applica tion
Dim objOutlookMsg As Outlook.MailIte m
Dim objOutlookRecip As Outlook.Recipie nt
Dim objOutlookAttac h As Outlook.Attachm ent
' Create the Outlook session.
Set objOutlook = CreateObject("O utlook.Applicat ion")
' Create the message.
Set objOutlookMsg = objOutlook.Crea teItem(olMailIt em)
With objOutlookMsg
' Add the To recipient(s) to the message.
Set objOutlookRecip = .Recipients.Add (Me.EMail)
objOutlookRecip .Type = olTo
.Display
End With
Set objOutlook = Nothing
End Sub
to send emails. Nonetheless, it opens Outlook and I would like it to send an
email using Outlook Express. Could anyone please oblige in ammending the
code for me, so that it uses Outlook Express 5?
Thanks
______________
Private Sub cmdSendEmail_Cl ick()
Dim objOutlook As Express.Applica tion
Dim objOutlookMsg As Outlook.MailIte m
Dim objOutlookRecip As Outlook.Recipie nt
Dim objOutlookAttac h As Outlook.Attachm ent
' Create the Outlook session.
Set objOutlook = CreateObject("O utlook.Applicat ion")
' Create the message.
Set objOutlookMsg = objOutlook.Crea teItem(olMailIt em)
With objOutlookMsg
' Add the To recipient(s) to the message.
Set objOutlookRecip = .Recipients.Add (Me.EMail)
objOutlookRecip .Type = olTo
.Display
End With
Set objOutlook = Nothing
End Sub
Comment