Nested tables and wdVerticalPositionRelativeToPage

B

Brian Bergstrom

Greetings;

I have some VBA that locates obects on a page and returns the
Selection.Information(wdVerticalPositionRelativeToPage) for further
processing.

I have noticed that if my selection is in a nested table, then
Selection.Information(wdVerticalPositionRelativeToPage) seems to return
the distance from the top of the inner table, and not the top of the
page as wdVerticalPositionRelativeToPage. You can notice the same thing
by watch the "At:" field on Word's bottom toolbar, when you enter a
nested table the field will claim you are higher that you are.

So, is there a way to get the valid vertical page information in nested
tables?

Thanks,
--Brian
 
W

Word Heretic

G'day "Brian Bergstrom" <[email protected].(nospam)>,

if its in a nested table, outnest and add what you find until not
nested


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

steve from wordheretic.com (Email replies require payment)
 
B

Brian Bergstrom

Not a bad idea, except there's no way to tell when you're out of a given
table.

There is no problem in the outter most table, so I'm not sure exactly
how you'd tell when you've 'outnested' when all you have is
Selection.Information(wdWithInTable).

Maybe it needs more thought.
--BB
 
W

Word Heretic

G'day "Brian Bergstrom" <[email protected].(nospam)>,

you set a range to the tables range and collapse it.

if that range.information shows to be withintable , repeat after
adding number.

No more thought - just you need to use collapse and use
..Range.Information(wdWithInTable)

<Bows>

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

steve from wordheretic.com (Email replies require payment)
 

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