Microsoft Excel - Hyperlinking How To…

I have a HUGE spreadsheet that I use for work where each customer gets 2 individual worksheets and there are rollup totals for those worksheets, etc… Navigating through this was initially a problem for me then I found out about Hyperlinking… I started out real simple… I created a blank worksheet, entered my customer names in one column and their customer number in a second column. As I said I had two worksheets for each customer one called INFOXX and the other called SHEETXX (where XX was just an incrementing number). To insert the hyperlink I right clicked Insert Hyperlinkon the customer name, selected HYPERLINK and from the Hyperlink dialog I told it I wanted to link to a “Place in this Document” (see image) and then I selected the correct INFOXX worksheet for that customer name. I did the same thing for the customer number only now I wanted to link to SHEETXX for that customer. I could now quickly get to both worksheets of customer information without having to try to figure out which one it was… and to make getting back to my Selection worksheet easier I just but a hyperlink on each INFOXX and SHEETXX with the word “BACK” to bring me back to the selection worskeet that I called CustomerSummary.The above handled 80% or more of my hyperlinking needs… but I wanted to fine-tune it a little bit so I decided to try to use the HYPERLINK formula where I could simply enter the INFO and SHEET number into a cell and have it automatically create the hyperlinks for me…. The resulting formula looks something like this…

=IF(B20=”",”",HYPERLINK(CONCATENATE(”[WorksheetName.xls]Sheet”,VALUE(B20),”!A1″),”?”))

Let’s break this down…

IF(B20=”",”",HYPERLINK…) - This is saying that if there isn’t a value in the B20 cell (in other words there are no SHEETXX worksheet then don’t put anything in the hyperlink just leave the cell blank. It is always a good idea to do some kind of a check like this so that you don’t end up with errors. [Keep in mind that if you put a number into B20 and there is no corresponding SHEETXX you will get a POPUP error in Excel telling you there is no reference.]

CONCATENATE(”[WorksheetName.xls]Sheet”,VALUE(B20),”!A1″) is telling Excel to combine together the text value of [WorksheetName.xls]Sheet, with the text value of B20 converted to a number, with the text value of !A1 resulting in a final text value of [WorksheetName.xls]Sheet5!A1 (assuming that B20 has a value of 5 in it).

The HYPERLINK formula then uses the newly created text value and attaches it to that funny “sun” type image so that on my spreadsheet the only thing that appears is the “sun”. When I click on the “sun” I am taken to cell A1 of the worksheet titled SHEETXX where the XX is equal to the value that is found in Cell B20.

If I copy this formula down the page, B20 becomes B21, B22, B23, B24, etc… and then all I need to do is enter a number into column B and it will link me to the sheet with the corresponding number.

To Hyperlink to the INFO sheets it is the same formula, just change SHEET to INFO. You also don’t have to use a funny symbol you could use words if you like.

It sounds more difficult than it really is.

This post was read 12 times until now

About the Author

Bill

One Response to “ Microsoft Excel - Hyperlinking How To… ”

  1. [...] A very quick and painless process and I know that it is correct every time and that I have the values placed into the fields that I need them in.  Since I use this to keep track of individual project information I could be adding projects at any time and this script really streamlined the process for me.  You can also learn how to use HYPERLINKING to navigate through a workbook like this on my other post located HERE. [...]

Leave a Reply

You can use these XHTML tags: <a href="" title=""> <abbr title=""> <acronym title=""> <blockquote cite=""> <code> <em> <strong>