Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hyperlink in email loaded from access 1

Status
Not open for further replies.

SpankYou

Programmer
Feb 24, 2003
211
GB
Hey

I currently have a report in access 2000, that when you close the report down you get the option to send an email to all of your users. This works fine, but I'd like to make the link that I have in the email it sends out a hyperlink. Currently the email format looks like this.

"
The New Report Is Complete -

C:\WINDOWS\Desktop\Forecast

Thanks
"

The code I have is...

myItem.Body = vbCrLf & "The New Report Is Complete - " & vbCrLf & vbCrLf & "C:\WINDOWS\Desktop\Forecast" & " - " & strDate & ".doc" & vbCrLf & vbCrLf & vbCrLf & "Thanks"

Any help would be great.

thanks

Sam
 
Ok Don't worry I have sorted it, If you want to know how just leave a post, cheers

Sam
 
Sam,

How did you manage it. I have been playing around with this for a few days but didn't really achieve what I wanted.



Matt
[rockband]
 
Well Firstly I removed the path and added A string variable called HypLink. Then I stored the file path as below in it...

'Declaration
Dim HypLink As String

HypLink = "file:///" & "C:\WINDOWS\Desktop\Billings%20Forecast" & "%20-%20" & strDate & ".doc"


'Code For Body
myItem.Body = vbCrLf & "The New Billings Forecast Is Complete - " & vbCrLf & vbCrLf & HypLink & vbCrLf & vbCrLf & vbCrLf & "Thanks"


The problem with mine was the spaces in the file name, of course html doesnt recognise spaces, and uses the "%20" to allocate a space, hope this helps,

Sam
 
Thanks Sam,

A star for your effort. Even though you answered your own question.

It has helped me out a lot.



Matt
[rockband]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top