Reputation: 81
In addition to the question : Change HTML email body font type and size in VBA, i would like to know how can i change both the font size & the font family with long name. Here is my code which change only the font size:
strbody = "<BODY style=" & Chr(34) & "font-size:12pt;" & Chr(34) & "font-family:Times New Roman" & Chr(34) & ">" & "Hello" & "</BODY>"
When i remove the font size from the code it's indeed change the font-family.
Thanks for your assistance,
Upvotes: 0
Views: 1137
Reputation:
Try using single quotes within the quoted string. It's allowed in HTML styles.
strbody = "<BODY style='font-size:12pt;font-family:Times New Roman'>" & "Hello" & "</BODY>"
Upvotes: 3