Hey Guys
I have some code making vba send an email via outlook.
The code will add some txt to the body of the email.
I am wondering if anyone knows how to make part of the txt in the body of the email bold?
I want this to be bold:
& vbLf & "Part 2" _
Cheers for your help
I have some code making vba send an email via outlook.
The code will add some txt to the body of the email.
I am wondering if anyone knows how to make part of the txt in the body of the email bold?
I want this to be bold:
& vbLf & "Part 2" _
Cheers for your help
Code:
Sub SendEmails()
Dim aOutlook As Object
Dim aEmail As Object, x As Long
Dim rngeAddresses As Range, rngeCell As Range, strRecipients As String
Dim lngCount As Long
Dim strDate As Date, strTitle As String, strSource As String, StrOutput As String, strMAgent As String
Dim colAttach As Object
Dim oAttach As Object
'set Importance
aEmail.Importance = 2
'Set Subject
aEmail.Subject = "Hello"
'Set Body for mail
aEmail.Body = "Part 1" _
[B]& vbLf & "Part 2" _[/B]
& vbLf & "Part 3"
'Send the email
aEmail.Body = aEmail.Body & strBody _
'return field names to first row of new sheet
rst.MoveNext
Loop
'Set attachment
aEmail.Attachments.Add StrOutput
'Set Recipient
aEmail.Cc = strRecipients
'Send Mail
aEmail.Display
'Pop up msg box advising who the email has been sent to
'MsgBox ("Email Sent to: " & strRecipients)
End Sub