Excel User Group
Microsoft Excel blogs, forums, files. Read, ask questions, provide answers.

How to activate a column of URLs...

Latest post Tue, Oct 11 2011 12:58 PM by RichAutechre. 2 replies.
  • Mon, Oct 10 2011 12:54 PM

    • RichAutechre
    • Top 500 Contributor
    • Joined on Thu, Sep 29 2011
    • San Francisco, CA
    • Posts 3
    • Points 47

    How to activate a column of URLs...

    I've got an entire column of URLs in a spreadsheet and I don't know how to make them all active links without going into each cell and activating them one-by-one.  Is there a way of selecting the entire column and turning them on?

     

     

    • Post Points: 21
  • Mon, Oct 10 2011 4:58 PM In reply to

    • PeterG
    • Top 25 Contributor
    • Joined on Mon, Feb 25 2008
    • Posts 88
    • Points 1,298

    Re: How to activate a column of URLs...

    I can think of two easy approaches to this problem.

    1. simply use the =HYPERLINK(reference,[friendly name]) formula to generate a column of hyperlinks adjacent to your column of URLs
    2. use the following VBA code to make a hyperlink in each cell that contains a URL

    Sub AddHyperlinks()
        Dim rngCe As Range
        On Error Resume Next
        For Each rngCe In Selection
            rngCe.Parent.Hyperlinks.Add anchor:=rngCe, Address:=rngCe.Value2
        Next rngCe
    End Sub

    Peter

     

    • Post Points: 21
  • Tue, Oct 11 2011 12:58 PM In reply to

    • RichAutechre
    • Top 500 Contributor
    • Joined on Thu, Sep 29 2011
    • San Francisco, CA
    • Posts 3
    • Points 47

    Re: How to activate a column of URLs...

    Thanks for that input.

    Since the values in that column are formulas themselves

    [="http://www.blahblah.com/"&[@[ColumnA]]

    ...I just tossed [=HYPERLINK({formula})] in there at the front.  

     

    Your input is appreciated.

    - Art

    • Post Points: 5
Page 1 of 1 (3 items) | RSS
Copyright Excel User Group and the relevant contributors, 2010. All Trade Marks acknowledged. This site is a peer-to-peer site and NOT affiliated in any way to Microsoft Corp. All rights reserved.