Current Page # (even vs odd)

J

jille

Hi,

I'm trying to write the code to determine:

a) what the current page number is (even where there is no page numbering
inserted in the doc) and;
b) determine if it is even/odd number (without 'reflected margin feature')

I have a large number of small documents that are being appended to one
another and I need to ensure that the first page always starts on an odd page.

Thanks,
Jille
 
G

Greg Maxey

Hi,

I'm trying to write the code to determine:

a) what the current page number is (even where there is no page numbering
inserted in the doc) and;
b) determine if it is even/odd number (without 'reflected margin feature')

I have a large number of small documents that are being appended to one
another and I need to ensure that the first page always starts on an odd page.

Thanks,
Jille

Maybe somethink like this:

Sub Scratchmacro()
Dim lngPN As Long
Dim lngCheck As Long
lngPN = Selection.Information(wdActiveEndPageNumber)
lngCheck = lngPN Mod 2
If lngCheck > 0 Then MsgBox "Page is odd"
End Sub
 

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