I am having issues embedding a hyperlink to some text like this.
I am running the macro from Excel which creates a Outlook object and repeats for all values down column c.
The below did not work so, how do I go about embedding a link here?
.Body = "Click Here <https://www.google.com/>
Code below
Dim OutApp As Object
Dim OutMail As Object
Dim cell As Range
Application.ScreenUpdating = False
Set OutApp = CreateObject("Outlook.Application")
On Error GoTo cleanup
For Each cell In Columns("B").Cells.SpecialCells(xlCellTypeConstants)
If cell.Value Like "?*@?*.?*" And _
LCase(Cells(cell.Row, "C").Value) = "yes" Then
Set OutMail = OutApp.CreateItem(0)
On Error Resume Next
With OutMail
.SentOnBehalfOfName = "urdearboy@needshelp.com"
.to = cell.Value
.Subject = "Subject" & Cells(cell.Row, "D").Value
.Body = "Click Here <https://www.google.com/>"
strLocation = "C:\Users\hahayouthought"
.Attachments.Add (strLocation)
.Display
End With
On Error GoTo 0
Set OutMail = Nothing
End If
Next cell