ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   VBA Code to go to one Bookmark. (https://www.excelbanter.com/excel-programming/409777-vba-code-go-one-bookmark.html)

Juan

VBA Code to go to one Bookmark.
 
I have a Tabe of Contents bookmarked on Page 2 titled Table_Of_Contents

Can someone help me on the VBA code. I have the following written but it
says that the bookmark does not exist.

Private Sub CommandButton1_Click()
Selection.GoTo What:=wdGoToBookmark, Which:=wdGoToFirst
End Sub

As a second question, is it possible to have this command button follow each
page on its own as someone scrolls through the document. It's a 115 page
document and i thought it would be easy for the button to float along each
page on the side.

Thanks.

Office_Novice

VBA Code to go to one Bookmark.
 
I think your question would be answered faster he

http://msdn.microsoft.com/newsgroups... lang=en&cr=US

"Juan" wrote:

I have a Tabe of Contents bookmarked on Page 2 titled Table_Of_Contents

Can someone help me on the VBA code. I have the following written but it
says that the bookmark does not exist.

Private Sub CommandButton1_Click()
Selection.GoTo What:=wdGoToBookmark, Which:=wdGoToFirst
End Sub

As a second question, is it possible to have this command button follow each
page on its own as someone scrolls through the document. It's a 115 page
document and i thought it would be easy for the button to float along each
page on the side.

Thanks.



All times are GMT +1. The time now is 03:47 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com