ms word: vba code for hyperlink to the page number

touchmove

New Member
Joined
May 18, 2015
Messages
10
Hi everyone!


Please allow me to post ms word question in this forum. Hoping there is some ms word expert there who may help me with my problem.

My boss wants me to create an hyperlink so that when I click a text it would link to a certain page number within the same file.

The problem is I need to create like 200 hyperlinks.

Here is the sample data:


Part I: General Requirements for Preventive Fire Protection in Buildings
Code
Page
General
1-1
7
Title
1 / 1-1
10
Purpose
2 /1-1
10

<tbody>
</tbody>


Now, when I click General, it should hyperlink to page 7 of the document. The problem is I have a lot of text to create an hyperlink to and create a vba code is surely a great help.
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
Why would you not post this in a Word forum where you probably have a better chance at getting the best answer? If you do, you should post here that you have cross posted there. From a quick Google search on "word vba code for hyperlink to page number" it is obvious that you are not the first to want to do this. From reading a couple of responses to that search, it is not something I as an Access/Excel vba user would wade into even though complete code functions were given to the requestor. Then again, maybe you will get lucky askin the question here.
 
Upvote 0

Forum statistics

Threads
1,213,539
Messages
6,114,221
Members
448,554
Latest member
Gleisner2

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top