referencing cells

S

skrimpy

In Word 2000 I have a table that stretches from page to page. I need t
reference the first, and last row on each page, although they are no
necessarily the first and last rows on the table. Is there any way t
do this? Thanks
Da
 
W

Word Heretic

G'day skrimpy <[email protected]>,

Use a Styleref field, otherwise you enter the province of manual
pagination.

Steve Hudson - Word Heretic
Want a hyperlinked index? S/W R&D? See WordHeretic.com

steve from wordheretic.com (Email replies require payment)


skrimpy reckoned:
 
S

skrimpy

Word said:
G'day skrimpy <[email protected]>,

Use a Styleref field, otherwise you enter the province of manual
pagination......


I guess I'm a bit of a novice. Not quite sure what that means but I
wrote a small loop that will hunt down the number of the last line on
page 1. I suppose with a little tweaking it will grab the last line
of the active page, or, whatever page you want. I dont quite
understand why I had to add the "-1" after the loop to get the
correct line number. It was adding an extra line for some reason.
Its in one of my other posts on this forum but it is incorrect and
needs some adjustment. Here is the good copy if you care.
The extra code after the loop was just a simple output to test and
see if I was getting the correct number. Thanks for the help!

Dim X, Y As Integer
X = 1
Y = 0
Do While X < 2
X = Selection.Information(wdActiveEndAdjustedPageNumber)
Selection.MoveDown Unit:=wdLine, Count:=1
Y = Y + 1
Loop

'output the number of lines below the table.
Selection.EndKey Unit:=wdColumn
Selection.MoveDown Unit:=wdLine, Count:=1
Selection.TypeText Text:=Y - 1
 
W

Word Heretic

G'day skrimpy <[email protected]>,

???

Steve Hudson - Word Heretic
Want a hyperlinked index? S/W R&D? See WordHeretic.com

steve from wordheretic.com (Email replies require payment)


skrimpy reckoned:
Word said:
G'day skrimpy <[email protected]>,

Use a Styleref field, otherwise you enter the province of manual
pagination......


I guess I'm a bit of a novice. Not quite sure what that means but I
wrote a small loop that will hunt down the number of the last line on
page 1. I suppose with a little tweaking it will grab the last line
of the active page, or, whatever page you want. I dont quite
understand why I had to add the "-1" after the loop to get the
correct line number. It was adding an extra line for some reason.
Its in one of my other posts on this forum but it is incorrect and
needs some adjustment. Here is the good copy if you care.
The extra code after the loop was just a simple output to test and
see if I was getting the correct number. Thanks for the help!

Dim X, Y As Integer
X = 1
Y = 0
Do While X < 2
X = Selection.Information(wdActiveEndAdjustedPageNumber)
Selection.MoveDown Unit:=wdLine, Count:=1
Y = Y + 1
Loop

'output the number of lines below the table.
Selection.EndKey Unit:=wdColumn
Selection.MoveDown Unit:=wdLine, Count:=1
Selection.TypeText Text:=Y - 1

 

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

Top