Hi,
I have this code
Sub Send()
Dim OutApp As Object
Dim OutMail As Object
Call SaveFile
Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)
On Error Resume Next
With OutMail
.To = "will.norris@email.org"
.Subject = "New User Requirements"
.Body = "A new users requirements form has been submitted for " & Range("D5") & " to be set up for the start date of " & Range("D9") & "The form is held in H:\Folder\Folder"
.Send
End With
On Error GoTo 0
Set OutMail = Nothing
Set OutApp = Nothing
End Sub
What I wanted to do was add a link to the 'H:\Folder\Folder' folder location, so that when the email is sent you would be able to click that link to follow it.
Any help would be excellent!
I figured it out now so dont worry!
If anyone is interested though I Changed my code to this.
Sub Send()
Dim OutApp As Object
Dim OutMail As Object
Call SaveFile
Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(0)
strbody = "<HTML><BODY>"
strbody = strbody & "<A href=J:\Projects\Folder%20Name>New User Requirements</A>"
strbody = strbody & "</BODY></HTML>"
On Error Resume Next
With OutMail
.To = "will.norris@email.org"
.Subject = "New User Requirements"
.HTMLBody = "A new users requirements form has been submitted for " & Range("D5") & " to be set up for the start date of " & Range("D9") & " The form is held in " & strbody
.Send
End With
On Error GoTo 0
Set OutMail = Nothing
Set OutApp = Nothing
End Sub
Bookmarks