DoCmd SendObject - send an email with a richtext formatted field - not working (1 Viewer)

atrium

Registered User.
Local time
Tomorrow, 00:40
Joined
May 13, 2014
Messages
348
The table filed is specified as Rich Text, the same field on the form is specified as Rich Text.

When I include the field in the body of the message I have all the html showing

I use

DoCmd.SendObject , , acFormatRTF, varName, varCC, , varSubject, varBody, False, False


Any help would be great
 

theDBguy

I’m here to help
Staff member
Local time
Today, 07:40
Joined
Oct 29, 2018
Messages
21,491
When you view the message in your email client, is there a setting to view it in rich text?
 
Last edited:

atrium

Registered User.
Local time
Tomorrow, 00:40
Joined
May 13, 2014
Messages
348
Thanks guys ,
I have tried acFormatRTF and acFormatHTML same result. The text comes out with all the html code

DoCmd.SendObject , , acFormatHTML, varName, varCC, , varSubject, varBody, False, False

DoCmd.SendObject , , acFormatRTF, varName, varCC, , varSubject, varBody, False, False
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 22:40
Joined
May 7, 2009
Messages
19,247
SendObject will not do it for you. Try Outlook automation.

For info, the TemplateFile argument only applies to Output format acFormatHtml and there is an object to send (report, table, query, etc).
Also the template will apply Not to the Body of the email, but to the Attachment (report, table, query, etc).
 

theDBguy

I’m here to help
Staff member
Local time
Today, 07:40
Joined
Oct 29, 2018
Messages
21,491
Thanks guys ,
I have tried acFormatRTF and acFormatHTML same result. The text comes out with all the html code

DoCmd.SendObject , , acFormatHTML, varName, varCC, , varSubject, varBody, False, False

DoCmd.SendObject , , acFormatRTF, varName, varCC, , varSubject, varBody, False, False
Hi. You didn't see my question. You can open an html file with a text editor and see all the tags. The only way to see it as a web page is to open it with a web browser or any application that can render html tags. It just so happens that Outlook can do both. That's why I asked if you can switch the view in your email client.
 

Users who are viewing this thread

Top Bottom