![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
I have been sending RTF report from Ms Access on the body of the email.
I need to send it in HTML format instead, but it is not working. The body of the email displays the whole source instead of the HTML formatted body. I have realized that the email format shows "Plain Text" and "Rich Text" format only. If you have further questions, please do not hesitate to contact me. Below there is an example of what I am getting, please check: HTMLHEADMETA HTTP-EQUIV="Content-Type" CONTENT="text/html;charset=windows-1252"TITLERental Confirmation/TITLE/HEADBODYTABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 TR HEIGHT=31 TD WIDTH=4 BR/TDTD WIDTH=228 FONT SIZE=5 FACE="Book Antiqua" COLOR=#000000Order Confirmation/FONT/TDTD WIDTH=108 FONT SIZE=1 FACE="Arial" COLOR=#000000 /FONT/TDTD WIDTH=348 FONT SIZE=5 FACE="Book Antiqua" COLOR=#000000EZ Wireless Communications/FONT/TD/TR/TABLETABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 TR HEIGHT=21 TD WIDTH=4 BR/TDTD WIDTH=92 FONT SIZE=3 FACE="Book Antiqua" COLOR=#000000Order No.:/FONT/TDTD WIDTH=576 FONT SIZE=3 FACE="Book Antiqua" COLOR=#0000007251/FONT/TD/TR/TABLETABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 TR HEIGHT=15 TD WIDTH=4 BR/TDTD WIDTH=668 FONT SIZE=1 FACE="Book Antiqua" COLOR=#000000Your cellular phone rental order has been received and processed. Please confirm the following rental information:/FONT/TD/TR/TABLETABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 TR HEIGHT=21 TD WIDTH=8 BR/TDTD WIDTH=372 BUFONT SIZE=3 FACE="Book Antiqua" COLOR=#0000ffCustomer Information:/FONT/B/U/TDTD WIDTH=292 BUFONT SIZE=3 FACE="Book Antiqua" COLOR=#0000ffDelivery Information:/FONT/B/U/TD/TR/TABLETABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 TR HEIGHT=15 TD WIDTH=8 BR/TDTD WIDTH=372 FONT SIZE= .......Etc...... If you copy the whole source in a HTML editor like dreamweaver, it gives you the exact format. I do not know if I have to change a setting in ms outlook or change the code I have which is: Dim strline, strHTML Dim OL As Outlook.Application Dim MyItem As Outlook.MailItem Set OL = New Outlook.Application Set MyItem = Outlook.Application.CreateItem(olMailItem) If Me.Status Like "*Reserved*" Or Me.Status Like "*rent*" Then DoCmd.OutputTo acOutputReport, "Rental Confirmation", acFormatHTML, "C:\Order.html" MyItem.Subject = "ORDER CONFIRMATION - Cellular phone rental Order" & " " & Me.Invoice_No End If Open "C:\Order.html" For Input As 1 Do While Not EOF(1) Input #1, strline strHTML = strHTML & strline Loop Close 1 If Left(OL.Version, 2) = "10" Then MyItem.bodyformat = olFormatHTML End if MyItem.Body = strHTML MyItem.To = Me.email MyItem.Display End Sub Thank you in advance for your help. |
Ads |
#2
|
|||
|
|||
![]()
You need to set HTMLBody, not Body.
-- Sue Mosher, Outlook MVP Author of Configuring Microsoft Outlook 2003 http://www.turtleflock.com/olconfig/index.htm and Microsoft Outlook Programming - Jumpstart for Administrators, Power Users, and Developers http://www.outlookcode.com/jumpstart.aspx wrote in message ups.com... I have been sending RTF report from Ms Access on the body of the email. I need to send it in HTML format instead, but it is not working. The body of the email displays the whole source instead of the HTML formatted body. I have realized that the email format shows "Plain Text" and "Rich Text" format only. If you have further questions, please do not hesitate to contact me. Below there is an example of what I am getting, please check: I do not know if I have to change a setting in ms outlook or change the code I have which is: Dim strline, strHTML Dim OL As Outlook.Application Dim MyItem As Outlook.MailItem Set OL = New Outlook.Application Set MyItem = Outlook.Application.CreateItem(olMailItem) If Me.Status Like "*Reserved*" Or Me.Status Like "*rent*" Then DoCmd.OutputTo acOutputReport, "Rental Confirmation", acFormatHTML, "C:\Order.html" MyItem.Subject = "ORDER CONFIRMATION - Cellular phone rental Order" & " " & Me.Invoice_No End If Open "C:\Order.html" For Input As 1 Do While Not EOF(1) Input #1, strline strHTML = strHTML & strline Loop Close 1 If Left(OL.Version, 2) = "10" Then MyItem.bodyformat = olFormatHTML End if MyItem.Body = strHTML MyItem.To = Me.email MyItem.Display End Sub Thank you in advance for your help. |
#3
|
|||
|
|||
![]()
Dear Sue Mosher,
Thank you for your reply. I have done the HTMLBody instead, but the message format is still in Rich Text. I got to menu, Format and shows Rich Text and Plain only. I do not know if Outlook 2000 supports HTML when sending a HTML report in body from ms access. Is that possible? Thank you |
#4
|
|||
|
|||
![]()
Dear Sue Mosher,
Your solution solved the problem. Thank you very much!!! Best Regards Danny |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
the "When sending meeting requests over the Internet, use iCalendar format" option unchecked and greyed-out | eric z | Outlook - Calandaring | 5 | February 23rd 06 09:55 PM |
sending html in body of outlook xp email | Help a Novice Please | Outlook - General Queries | 3 | February 22nd 06 07:50 AM |
Strange Outlook Problem when sending HTML Mail | Feezie | Outlook - General Queries | 0 | February 15th 06 05:55 PM |
sending email with pictures in other than html text | Tim | Outlook - General Queries | 1 | February 9th 06 10:23 AM |
Include PictureFormatHTML send picture will not remain checked | JimM | Outlook Express | 3 | January 9th 06 03:12 AM |