How do I convert a column of text URLs into active hyperlinks in Excel?

后端 未结 22 2180
刺人心
刺人心 2020-12-07 07:42

I have a column in excel, wherein I have all the website url values. My question is I want to turn the url values to active links. There are about 200 entries in that column

22条回答
  •  执念已碎
    2020-12-07 08:17

    Create the macro as here:

    On the Tools menu in Microsoft Excel, point to Macro, and then click Visual Basic Editor. On the Insert menu, click Module. Copy and paste this code into the code window of the module. It will automatically name itself HyperAdd.

    Sub HyperAdd()
    
        'Converts each text hyperlink selected into a working hyperlink
    
        For Each xCell In Selection
            ActiveSheet.Hyperlinks.Add Anchor:=xCell, Address:=xCell.Formula
        Next xCell
    
    End Sub
    

    When you're finished pasting your macro, click Close and Return to Microsoft Excel on the File menu.

    Then select the required cells and click macro and click run.

    NOTE Do NOT select the whole column! Select ONLY the cells you wish to be changed to clickable links else you will end up in a neverending loop and have to restart Excel! Done!

提交回复
热议问题