Excel 2007 - Hyperlink Text Within A Cell

  • SnookerFan

    Is it possible to insert a hyperlink which affects text within a cell?

    For example:

    | See this link | <-- Only the word "link" should be highlighted here.

    Before answering, please be aware of the following: I have seen many tutorials which use a formula (="See this " &HYPERLINK("http://www.superuser.com","link")) in order to insert a hyperlink already; I have 149 words within this cell, spaced out over many lines, and this method does not work with such a large amount of text as it exceeds 255 characters.

    Many thanks.

  • Answers
  • SnookerFan

    Going by suggestions found on Super User and elsewhere, I have come to the conclusion that the only way to "achieve" the desired results is as follows:

    Apply a link to the entire cell (which is the case whether we like it or not) and then to simply format the rest of the text - excluding the desired "link text" - to the standard format of the document, leaving the "link text" resembling a hyperlink. Or, you could reverse the process and colour the "link text" to resemble a hyperlink, leaving the remainder of the text to follow the standard format set by the document.

  • Jook

    Basically you confirmed my suspicion and answered this already:

    If it does not work in the small example, it won't in the big.

    Here are some other related questions, which came to the conclusion, that it is not possible to solve this with excel in this exact way.


    Hyperlinking a piece of text in Excel

  • Related Question

    Extract Hyperlink in Excel 2007
  • Questioner

    I have the following question:

    I have 2 sheets in Excel. The first one is used to collect all information from sheet 2. The cells are linked to sheet 2. My problem is that I can't link a hyperlink from sheet2 to a cell from sheet one. It only "extracts" the text.

    Cell 1 Sheet 2
    Test -> with hyperlink(file:///C:\test.pdf)

    Cell 1 Sheet 1

    How do I get the hyperlink into sheet1?

  • Related Answers
  • Ivo Flipse

    Here's what Excel help says about hyperlinks:

    Use another cell on the worksheet for the link target To quickly update all formulas in a worksheet that use a HYPERLINK function with the same arguments, you can place the link target in another cell on the same or another worksheet, and then use an absolute reference to that cell as the link_location in the HYPERLINK formulas. Changes that you make to the link target are immediately reflected in the HYPERLINK formulas.

    =HYPERLINK($Z$1) In cell Z1, you then enter the path to the link target.

    So you could make a link on Cell 1 on Sheet 1 referring to the link that's on Cell 1 Sheet 2

    Or try this solution they mentioned on EE:

    Paste the code below into a module (ALT + F11)

    Function GetAddress(HyperlinkCell As Range)
        GetAddress = Replace _
        (HyperlinkCell.Hyperlinks(1).Address,"mailto:", "")
    End Function

    from your worksheet to extract the hyperlink address