What I am trying to do is create a Hyperlink on a sheet in a workbook that I am creating using MS Access and VBA code.
I have the “Return to Contents” working on the individual tabs in the workbook.
wksTemp.Cells(1, 1).Hyperlinks.Add anchor:=wksTemp.Cells(1, 1), Address:=””, SubAddress:=”‘Contents’!A1″, ScreenTip:=”Click to Return to Contents”, TextToDisplay:=”Contents”
What is giving me headaches is trying to set the hyperlinks on the Contents tab.
I have about 121 rows and each one will hyperlink to the corosponding tab in the workboook. I could hard code each one, but that would require much time and would have to be modified each time a new company was added or removed from the list.
Is there a way to modify the Hyperlink statement so that I can dynamiclly populate the SubAddress, ScreenTip, and TextToDisplay?
Thank you for any help you can provide with this issue.