Re: word macro - navigaiton at pages by macropod
macropod
Tue Feb 06 04:23:34 CST 2007
Hi albatros,
The following might give you a few clues:
Go to Top of Current Page
Selection.GoTo What:=wdGoToPage, Name:=""
Go to A Particular Page
Selection.GoTo(What:=wdGoToPage, Name:="4")
Determine The Page Number At The Current Cursor Position.
Selection.Information(wdActiveEndPageNumber)
Go to the Next Page
MyPage = Selection.Information(wdActiveEndPageNumber)
Selection.GoTo What:=wdGoToPage, Name:=MyPage + 1
Go to the Previous Page
MyPage = Selection.Information(wdActiveEndPageNumber)
Selection.GoTo What:=wdGoToPage, Name:=MyPage - 1
Cheers
--
macropod
[MVP - Microsoft Word]
"albatros" <albatros@discussions.microsoft.com> wrote in message news:1C6C54BE-8AFF-4597-B1E1-4B3C265EA578@microsoft.com...
| hi,
|
| There are 3 command button, "next page", "previous page" and "first page".
|
| I use [appliacation.browser.next] and [application.browser.previous] for
| "next page" and "previous page", ok.
|
| ///not: for ex. 6 pages ahead I use a for loop: for i=1 to 6:
| app.browser.next: next i/
|
| and for the "first page" what should I use ?
|
| Or is there an alternative way for navigation over the pages ?
|
|
|
|
|