I am using a custom code to generate email on outlook from excel.
The code works, But I seek to set a custom size of font used on the body.
As in the below code , I set font properties ( type , size & color ) , and it applied correctly except the size.
If I set the size on code = 5 but in the email itself it became = 18.
If I set the size on code = 6 but in the email itself it became =24.
Also ,why vbTab has no effect at all (it does not insert a tab at beginning of the second line).
In advance, grateful for all your help.
Sub Send_Email()
Dim objOutlookApp As New Outlook.Application
Dim myEmail As Outlook.MailItem
Set myEmail = objOutlookApp.CreateItem(olMailItem)
myEmail.BodyFormat = olFormatHTML
myEmail.Display
Dim Strbody As String
Strbody = "<h5>Dears,</h5>" & vbCrLf & vbTab & _
"<font face = Times New Roman size= 5 font color=Brown>This a test string</font>"
myEmail.HTMLBody = Strbody & myEmail.HTMLBody
End Sub