i am currently working on a project of outlook automation
i want to change the font size of th message i get this error.
This method or property is not available because the current selection is in the mail header.
how do i select the message body
this is the code
this is where i get the error
i want to change the font size of th message i get this error.
This method or property is not available because the current selection is in the mail header.
how do i select the message body
this is the code
Code:
Dim OLApp As Outlook.Application
Dim myOLMailItem As Outlook.MailItem
Set OLApp = CreateObject("Outlook.Application")
Set myOLMailItem = OLApp.CreateItem(OLMailItem)
myOLMailItem.FormDescription.UseWordMail = True
Set Fill = selection.InlineShapes.AddPicture("\\SERVER\Data\xxxxx.jpg", False, True)
Fill.Height = 25.19
Fill.Width = 46.79
selection.Font.Name = "Alaska"
this is where i get the error