Create hyperlinks to each sheet using VBA

  • Thread starter Thread starter Steve Mackay
  • Start date Start date
S

Steve Mackay

I have a simple macro for listing all the worksheets in a workbook,
essentially creating a table of contents for my file:

Sub ListSheets()
For iSheets = 1 To Sheets.Count
ActiveCell.Value = Sheets(iSheets).Name
ActiveCell.Offset(1, 0).Activate
Next iSheets
End Sub

What I would like to do is make each of those cells a hyperlink to the
corresponding worksheet, to cell A1. Any ideas?

Thanks,
Steve Mackay
 
Thanks, Tom.

There is a lot of good information here. I am a rookie to VBA, so most
of it is over my head, but I cut and paste the macro into a module and
it worked as i wanted it to.


Thanks for your help.
Steve
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top