Consulting

Results 1 to 9 of 9

Thread: Solved: Full Path Not Showing in Hyperlink

  1. #1
    VBAX Regular
    Joined
    Aug 2004
    Location
    Manchester UK
    Posts
    16
    Location

    Solved: Full Path Not Showing in Hyperlink

    Evening all,

    I'm using Outlook 2K, and Excel 2K. I am auto generating messages and sending from Excel and almost everything is sweet.

    My only problem is this. In the body of the message I have the network path of a document, for example . .

    \\Btd2mbr22\Home\staticbob\Site Workbook testfile\03.00 Site Recs\03.10 (A) CVIs and Reg\

    . . . and the problem I have is seen there ! Is there anyway to ensure that the hyperlink formatting is active for the entire path, not just to the first space ?!!

    Hopefully, there is something I can do to the format of the string I am using in excel to sort this, rather that Outlook settings !

    Thanks in advance !
    Bob

  2. #2
    VBAX Tutor jamescol's Avatar
    Joined
    May 2004
    Location
    Charlotte, NC
    Posts
    251
    Location
    Hi Bob,
    This issue trips up a lot of folks - the fix is easy. Just enclose your URL with < > symbols. Office apps treat everything between these symbols as a URL. In your case:

    <\\Btd2mbr22\Home\staticbob\Site Workbook testfile\03.00 Site Recs\03.10 (A) CVIs and Reg\>


    Cheers,
    James
    "All that's necessary for evil to triumph is for good men to do nothing."

  3. #3
    VBAX Regular
    Joined
    Aug 2004
    Location
    Manchester UK
    Posts
    16
    Location
    Thanks James,

    I've tried that mate and it still doesn't seem to work, Outlook actually shows the <> but with no formatting ?

    I have posted the relevant part of my Excel code below, the var "savepath" is passed into this code, and is just a reference to a cell containing the document UNC path. (as example in OP)

    Perhaps I am better to add a shortcut to this file rather than adding a text hyperlink ? I believe that all that I need to do is add attachment by ref, but am not sure of the syntax ?

    Thanks in advance,
    Bob

    [VBA] 'Get info and send mail
    With safeitem.Item
    .subject = Worksheets("directory").Range("B3").Value & " - Workbook Notification"
    .Body = "This message has been generated automatically." & vbNewLine & vbNewLine & _
    "A new " & docname & " has been created in this location. Please click the link to view . . ." & vbNewLine & vbNewLine & _
    savepath
    End With

    safeitem.send
    Set mi = Nothing
    If Created Then appOutlook.Quit
    Set appOutlook = Nothing
    End Sub [/VBA]

  4. #4
    VBAX Tutor jamescol's Avatar
    Joined
    May 2004
    Location
    Charlotte, NC
    Posts
    251
    Location
    Bob,
    A couple of questions:

    What email editor are you using for Outlook - Word, RTF, HTML, Plain Text?
    At what service pack level is your Office 2000?

    Thanks,
    James
    "All that's necessary for evil to triumph is for good men to do nothing."

  5. #5
    VBAX Regular
    Joined
    Aug 2004
    Location
    Manchester UK
    Posts
    16
    Location
    James,

    I'm on HTML editor for Outlook. I'm now running 2003, but this was still the same case in 2000 and all of my users are on 2000 SP4 We need to stay with HTML editor as we have fancy signatures)

    I think the shortcut attachment would be best thinking about it . . .

    Cheers
    Bob

  6. #6
    Site Admin
    The Princess
    VBAX Guru Anne Troy's Avatar
    Joined
    May 2004
    Location
    Arlington Heights, IL
    Posts
    2,530
    Location
    Take the spaces out.
    ~Anne Troy

  7. #7
    VBAX Regular
    Joined
    Aug 2004
    Location
    Manchester UK
    Posts
    16
    Location
    Thanks Guys,

    I have sorted it. the last line of code for the body of my text now reads . .

    "<" & savepath & ">"

    And it all works well.

    Thanks
    Bob

  8. #8
    VBAX Tutor jamescol's Avatar
    Joined
    May 2004
    Location
    Charlotte, NC
    Posts
    251
    Location
    Bob,
    Glad you got it working!

    James
    "All that's necessary for evil to triumph is for good men to do nothing."

  9. #9
    VBAX Regular
    Joined
    Aug 2004
    Location
    Manchester UK
    Posts
    16
    Location
    James,

    This only works if I have Mail Format set to Rich Text in Outlook, if I have it set to HTML this doesn't show. Can you think of any other solution ?

    What code do I need to add a shortcut attachment to the message ???

    Thanks
    Bob

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •