| |
kevinmortimer
Posts: 19
Score: 0
Joined: 8/15/2006
From: London
Status: offline
|
Hi I have a similar problem and have tried the Char(34) option. Basicaly I am using a html to create the body of an email. All works fine with normal HTML but I am now trying to use Cascading style sheet code to keep the formating ( Bold colour ) of my text ( I pull the formatted text from by database already in CSS code). The CSS code uses quotation marks in its code. I have also tried using single quotes with no joy. My vbs code works ok with both Char(34) and single quotation marks but in the body of my email I loose the formating. Is there another option to escape the quotation marks that will allow the formatting to be retained. Below is my code Dim OutApp Dim OutMail Dim strbody Dim SigString Dim Signature Set OutApp = CreateObject("Outlook.Application") OutApp.Session.Logon Set OutMail = OutApp.CreateItem(0) On Error Resume Next With OutMail .To = "sandra@sublime-solutions.co.uk" .CC = "" .BCC = "" .Subject = "Attached CVs" .HTMLBody = "<HTML><body><font size = 3 color = Black face = Verdana><SPAN STYLE= Chr(34)font-family: 'Verdana';font-size: 12px;Chr(34) >Hi Derek<BR><BR></SPAN> <SPAN STYLE= Chr(34)font-family: 'Verdana';font-size: 12px;color: #0033FF;Chr(34) >Thank you</SPAN> <SPAN STYLE= Chr(34)font-family: 'Verdana';font-size: 12px;Chr(34) > very much </SPAN> <SPAN STYLE= Chr(34)font-family: 'Verdana';font-size: 12px;font-weight: bold;Chr(34) >for taking</SPAN> <SPAN STYLE= Chr(34)font-family: 'Verdana';font-size: 12px;Chr(34) > the time to interview <BR><BR><BR></SPAN> </FONT></BODY></HTML>" .Display End With On Error GoTo 0 Set OutMail = Nothing Set OutApp = Nothing
|
|