J
Jon Lewis
I'm trying to code a routine in VBA from Access to send a standard e-mail to
a group of clients. However, I can't figure out how to have standard
content in the body of the message.
If I manually create a new message with the required content (could be text
graphics or both) and then save the message as an Outlook Template (oft
file) , I can choose File>New>Choose Form>User Templates in File System...
and pick my saved oft file I get my required contect in the message body as
required.
How do I replicate this with Automation?
If I use the CreateItemFromTemplate method,
(Set objOutlookMsg = objOutlook.CreateItemFromTemplate(strTemplate))
in the resultant message created, the text in the message body of my saved
template does not appear at all and the graphical objects don't appear in
the body but may or may not appear as attachments acording to their
object/file type. (I'm setting the OlBodyFormat to olFormatHTML BTW)
Should I be using another method?
Also is there any way through Automation to handled of the "A program is
trying to access e-mail addresses..." Outlook security dialog which appears
3 times per email created if objOutlookMsg.Save and objOutlookMsg.Send are
used.
TIA
a group of clients. However, I can't figure out how to have standard
content in the body of the message.
If I manually create a new message with the required content (could be text
graphics or both) and then save the message as an Outlook Template (oft
file) , I can choose File>New>Choose Form>User Templates in File System...
and pick my saved oft file I get my required contect in the message body as
required.
How do I replicate this with Automation?
If I use the CreateItemFromTemplate method,
(Set objOutlookMsg = objOutlook.CreateItemFromTemplate(strTemplate))
in the resultant message created, the text in the message body of my saved
template does not appear at all and the graphical objects don't appear in
the body but may or may not appear as attachments acording to their
object/file type. (I'm setting the OlBodyFormat to olFormatHTML BTW)
Should I be using another method?
Also is there any way through Automation to handled of the "A program is
trying to access e-mail addresses..." Outlook security dialog which appears
3 times per email created if objOutlookMsg.Save and objOutlookMsg.Send are
used.
TIA