Hi Gary,
you're welcome
just put it in the "With" structure with everything else
With outMsg
'statements
.SenderEmailAddress = Me.eMailAddress
'statements
End With
Warm Regards,
Crystal
*
have an awesome day
*
MVP Access
Remote Programming and Training
strive4peace2006 at yahoo.com
*
Gary Dolliver wrote:
Hi Crystal,
Sorry I did not reply sooner to this one. First and foremost, thank you.
Second, how would I set up the sender property? I do not see it in the below
code and was hoping you might be able to help me out?
Thank you!
-gary
:
Hi Gary,
No, here are the parameters for SendObject
'SendObject
'[objecttype]
'[, objectname]
'[, outputformat]
'[, to]
'[, cc]
'[, bcc]
'[, subject]
'[, messagetext]
'[, editmessage]
'[, templatefile]
here is some code posted by Ricky Hicks for using the Outlook Reference
Library ...
'~~~~~~~~~~~`
Function MailParameters()
Dim outApp As Outlook.Application, outMsg As MailItem
Set outApp = CreateObject("Outlook.Application")
Set outMsg = outApp.CreateItem(olMailItem)
With outMsg
'.Importance = olImportanceHigh
.To = Me.eMailAddress
'.CC = "CC EMAIL ADDRESS GOES HERE"
'.BCC = "BCC EMAIL ADDRESS GOES HERE"
.Subject = "YOUR SUBJECT GOES HERE"
.Body = "YOUR_E-MAIL_MESSAGE_GOES_HERE"
'.Attachments.Add _
"YOUR FILE PATH AND NAME", , , "YOUR FILES NAME"
' If you want to edit before sending
.Display
'otherwise, to just send without looking...
'.Send
End With
Set outApp = Nothing
Set outMsg = Nothing
End Function
'~~~~~~~~~~~`
using this method, there IS a SenderEmailAddress property...
Warm Regards,
Crystal
*
have an awesome day
*
MVP Access
Remote Programming and Training
strive4peace2006 at yahoo.com
*
Gary Dolliver wrote:
Hello,
Is it possible to use the SendObject command, but have the email come from a
specific email address? Currently, every email that I send via the form
comes from
my default email address (I have multiple email addresses that come directly
to me) - I would like it instead to come from a generic email like
'(e-mail address removed)' I am using Outlook 2003.
Please let me know, thanks!
-gary