I have sorted out everything I need for sending emails to a list of people from an Access database, except setting the FROM: field in the outlook message. Can anyone point me in the right direction?
NOt sure what you mean by mechanism, but I have included some of the code below - hopefully that will answer your question. this is all linked to a command button.
thanks
***********************************************
Set objOutlook = New Outlook.Application
Set objEmail = objOutlook.CreateItem(olMailItem)
' ***creates and sends email
With objEmail
.TO = EMailAddress
.Subject = "Course Reminder - " & CourseName
.Body = "Hi " & FirstName & Chr(13) & Chr(13) & _
"This is a reminder that your course - " & CourseName _
& " is starting at " & StartTime _
& " today" & Chr(13) & Chr(13) & _
"If you are unable to attend, please let us know as soon as possilbe" & Chr(13) & Chr(13) & _
"Thanks" & Chr(13) & Chr(13) & _
"Training People"
' .Send
.Display
.GetInspector.WindowState = olNormalWindow
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.