Results 1 to 5 of 5
  1. #1
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    Cincinnati, Ohio, USA
    Posts
    7,089
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Show me the URL! (10.0/2002)

    Outlook 2000 did this with ease....but I can't seem to find a consistent setting in Outlook 2002 to enable it:

    How in the world can I force Outlook to show me the URL in an HTML message, down in the status bar? How very handy that little missing feature is when you're stuck at 26.4K on a dial-up and you don't want to open a window full of advertisements!
    -Mark

  2. #2
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Show me the URL! (10.0/2002)

    OL2000 doesn't do it by default, at least in CW mode. Maybe you had an add-in? If I really want to know, I run this macro:

    <pre>Sub LinkLister()
    'Copyright 2001 Jefferson Scher - 3/17/01; updated 1/3/02
    'Check whether one or more messages or other OL items is open and proceed
    ' accordingly
    intNoteCount = 0 'module level integer variable
    Select Case Inspectors.Count
    Case 0 'no items are open, but it might be a mail folder
    If ActiveExplorer.Selection.Count = 0 Then
    MsgBox "Select or open an HTML message first, then try again."
    Else 'one or more items are selected in this folder
    If ActiveExplorer.Selection.Item(1).Class = olMail Then
    Dim aMsg As MailItem, bolNoHTML As Boolean
    bolNoHTML = True
    For Each aMsg In ActiveExplorer.Selection
    If aMsg.HTMLBody <> vbNullString Then
    Call LinksToNote(aMsg)
    bolNoHTML = False
    End If
    Next
    If bolNoHTML Then
    MsgBox "None of the selected messages is HTML."
    End If
    Else
    MsgBox "This lister works only in a mail folder."
    Exit Sub
    End If
    End If
    Case 1 'check only the open item
    If ActiveInspector.EditorType <> olEditorHTML Then
    MsgBox "Not an HTML message."
    Exit Sub
    Else
    Call LinksToNote(ActiveInspector.CurrentItem)
    End If
    Case Else 'iterate through mutiple open items
    Dim anInsp As Inspector
    Dim msgArray() As MailItem, intCount As Integer
    ReDim msgArray(1 To 5)
    intCount = 0
    For Each anInsp In Inspectors
    If anInsp.EditorType = olEditorHTML Then
    intCount = intCount + 1
    If intCount <= 5 Then
    Set msgArray(intCount) = anInsp.CurrentItem
    Else
    ReDim Preserve msgArray(1 To intCount)
    Set msgArray(intCount) = anInsp.CurrentItem
    End If
    End If
    Next
    If intCount = 0 Then
    MsgBox "No HTML messages to examine."
    Exit Sub
    Else
    For intCount = 1 To UBound(msgArray())
    If msgArray(intCount) Is Nothing Then Exit For
    Call LinksToNote(msgArray(intCount))
    Next
    End If
    End Select
    End Sub

    Sub LinksToNote(myMailItem As MailItem)
    'Copyright 2001 Jefferson Scher - 3/17/01; updated 1/3/02
    Dim strCodeArray() As String
    If myMailItem.HTMLBody <> vbNullString Then
    strCodeArray = Split(myMailItem.HTMLBody, "href=", , vbTextCompare)
    Else 'this is very rare and inexplicable
    strCodeArray = Split(myMailItem.Body, "href=", , vbTextCompare)
    End If
    If UBound(strCodeArray()) = 0 Then
    If Inspectors.Count = 1 Then
    MsgBox "No links found in """ & myMailItem.Subject & """"
    End If
    Set myMailItem = Nothing
    Exit Sub
    End If
    Dim strNoteBody As String, intCount As Integer, intFirstGT
    Dim myNote As NoteItem
    Set myNote = CreateItem(olNoteItem)
    myNote.Width = 600
    myNote.Height = 500
    strNoteBody = "Links in -> " & myMailItem.Subject & vbCrLf & "(From -> "
    strNoteBody = strNoteBody & myMailItem.SenderName & " - at - "
    strNoteBody = strNoteBody & myMailItem.SentOn & ")"
    Set myMailItem = Nothing
    For intCount = 1 To UBound(strCodeArray())
    strCodeArray(intCount) = Replace(strCodeArray(intCount), vbCrLf, " ")
    intFirstGT = InStr(1, strCodeArray(intCount), ">")
    If InStr(1, strCodeArray(intCount), "</a>", vbTextCompare) > 0 Then
    strNoteBody = strNoteBody & vbCrLf & vbCrLf & _
    "Desc: " & Mid(strCodeArray(intCount), _
    intFirstGT + 1, InStr(1, strCodeArray(intCount), "</a>", _
    vbTextCompare) - (intFirstGT + 1)) & vbCrLf
    strNoteBody = strNoteBody & "URL: " & Mid(strCodeArray(intCount), 1, _
    intFirstGT - 1)
    ElseIf intFirstGT > 0 Then
    Dim lngElementLen As Long, intDescLen As Integer
    lngElementLen = Len(strCodeArray(intCount))
    If lngElementLen - (intFirstGT + 1) < 15 Then
    intDescLen = lngElementLen - (intFirstGT + 1)
    Else
    intDescLen = 15
    End If
    If intDescLen > 0 Then
    strNoteBody = strNoteBody & vbCrLf & vbCrLf & _
    "Desc: [Link not closed; beginning of description is: " & _
    Mid(strCodeArray(intCount), _
    intFirstGT + 1, intDescLen) & "]" & vbCrLf
    Else
    strNoteBody = strNoteBody & vbCrLf & vbCrLf & _
    "Desc: [Link not closed; no description available]" & _
    vbCrLf
    End If
    strNoteBody = strNoteBody & "URL: " & Mid(strCodeArray(intCount), 1, _
    intFirstGT - 1)
    Else
    strNoteBody = strNoteBody & vbCrLf & vbCrLf & _
    "[Link could not be decoded]" & vbCrLf
    End If
    Next
    strNoteBody = Replace(strNoteBody, " ", " ")
    strNoteBody = Replace(strNoteBody, "

  3. #3
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    Cincinnati, Ohio, USA
    Posts
    7,089
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Show me the URL! (10.0/2002)

    Ah! But this works in OL2000. At home, I use 2000, in IO mode. At the office, they saw fit to saddle me with Office XP, and OL2002 in IO mode there does not show links in the status bar. So what we are looking at here is essentially the same configuration, right down to the PST file, and the only difference is in the version number.

    My guess is that Microsoft either a) decided I and the rest of the world didn't need to see URLs for HTML messages or [img]/forums/images/smilies/cool.gif[/img] it's just another one of those weird Office things that really has no good explanation. It's stimple, I want the URL in the status bar. That's all. Nothing big. But the Dark Side (apologies to Woody) apparently doesn't see it that way. <img src=/S/hairout.gif border=0 alt=hairout width=31 height=23>
    -Mark

  4. #4
    Plutonium Lounger Leif's Avatar
    Join Date
    Dec 2000
    Location
    U.K.
    Posts
    14,010
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Show me the URL! (10.0/2002)

    Convoluted - but I found an answer for you.
    I came across an MS article that mentioned that hyperlinks in Outlook 2002 are now recognized in the Subject field. So I had a little play around....

    With the mail open, move the mouse over the hyperlink until it changes to the pointing finger. Left_click and hold, then drag to the subject field.

    Of course, it adds the url to the subject and you get asked if you want to save any changes etc., but at least you can see what it is.

  5. #5
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    Cincinnati, Ohio, USA
    Posts
    7,089
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Show me the URL! (10.0/2002)

    Huh, much more convoluted. But a solution's a solution, no? Maybe I can use that as leverage for my company to spring for a nice, 21" display? <img src=/S/scratch.gif border=0 alt=scratch width=25 height=29>

    Thanks Leif!
    -Mark

Posting Permissions

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