Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Create hyperlink to another sheet

The first sheet of my workbook is like a contents page. Each cell in column A holds an IP address string. For each IP address string, there is a worksheet named with the IP address.

I want to turn the string in the cells in column A into hyperlinks to their corresponding sheets (cell A1 of the destination sheet).

I only need the VBA line that makes the hyperlink; I can figure out the looping, etc. Remember that the name of the sheet to be linked to is the same as the value of the cell that will become the link.

Research has only brought up forum posts that give a stack of code without explaining any of it.

like image 782
Swiftslide Avatar asked Mar 21 '12 21:03

Swiftslide


People also ask

Can a hyperlink switch to another worksheet?

Change link destination If you want to change the hyperlink destination, you need to modify the cell reference or choose another sheet. You can do both, if necessary. Right-click the hyperlink you want to edit. Choose Edit Hyperlink from the popup menu.

Can you hyperlink to a specific sheet in Excel?

Use the tools in the middle of the dialog box to navigate and select the Excel workbook you want linked to. The address of that file should appear in the Address box. Change the Text to Display box so it contains whatever you want in the document; this is the text that will be clickable as the hyperlink. Click OK.


1 Answers

I recorded a macro making a hiperlink. This resulted.

ActiveCell.FormulaR1C1 = "=HYPERLINK(""[Workbook.xlsx]Sheet1!A1"",""CLICK HERE"")"
like image 106
curial Avatar answered Sep 23 '22 08:09

curial