Page Numbering Incorrect: Word 03 --> .PDF

H

Hans

I have set up several hundred Word docs with some code I got on the 'net (via
this forum) that automatically determines if the doc ends on an odd or even
page, then, if odd, adds a page and the text "This page intentionally left
blank."

When I convert the docs using Acrobat Pro, if the doc naturally has an even
number of pages, say, four, then the "Page # of #" in the footer is incorrect
when converted to PDF, i.e., it the Total Pages digit is too high by one,
e.g., "Page 4 of 5." It's as if Word is suppressing a last page because it's
odd-numbered when viewed from within Word (and when a hard-copy is printed),
but it is not suppressed when distilled to PDF.

Is there a solution to this other than nixing the "Page # of #" format?

Thanks!
 
M

macropod

Hi Hans,

That may depend on how you're adding the extra page. For example, one might do it through vba or via field coding. Perhaps if you
post the code you're using, a solution can be suggested.

Cheers
 
J

Jean-Guy Marcil

Hans said:
I have set up several hundred Word docs with some code I got on the 'net (via
this forum) that automatically determines if the doc ends on an odd or even
page, then, if odd, adds a page and the text "This page intentionally left
blank."

When I convert the docs using Acrobat Pro, if the doc naturally has an even
number of pages, say, four, then the "Page # of #" in the footer is incorrect
when converted to PDF, i.e., it the Total Pages digit is too high by one,
e.g., "Page 4 of 5." It's as if Word is suppressing a last page because it's
odd-numbered when viewed from within Word (and when a hard-copy is printed),
but it is not suppressed when distilled to PDF.

Word does not suppress pages...

The usual error for the Page x of y is:
Page 1 of 1
Page 2 of 2
Page 3 of 3
etc.

You say you get
Page 4 of 5

This is a new one!

How many pages are there in the PDF file, 4 or 5?

And just to be clear, *all* documents with an even number of pages exhibit
this behaviour, whereas those with an odd number do not, even if your code
actually adds a page to make the number of pages even just prior to PDF
ceation. Is that correct?

If that is the case, maybe your code is doing something it shouldn't?
 
H

Hans

Hello,

Here is the page, via MVPS' FAQ on Tables, Fields, & Forms, from which I got
the field coding:

http://word.mvps.org/FAQs/TblsFldsFms/InsEvnPgEndChap.htm

Note that I could not get it to work as written -- I had to add a space
between the word "IF" and the curly bracket to the right (see link above).

Thanks for your assistance,

-Hans


macropod said:
Hi Hans,

That may depend on how you're adding the extra page. For example, one might do it through vba or via field coding. Perhaps if you
post the code you're using, a solution can be suggested.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Hans said:
I have set up several hundred Word docs with some code I got on the 'net (via
this forum) that automatically determines if the doc ends on an odd or even
page, then, if odd, adds a page and the text "This page intentionally left
blank."

When I convert the docs using Acrobat Pro, if the doc naturally has an even
number of pages, say, four, then the "Page # of #" in the footer is incorrect
when converted to PDF, i.e., it the Total Pages digit is too high by one,
e.g., "Page 4 of 5." It's as if Word is suppressing a last page because it's
odd-numbered when viewed from within Word (and when a hard-copy is printed),
but it is not suppressed when distilled to PDF.

Is there a solution to this other than nixing the "Page # of #" format?

Thanks!
 
H

Hans

Responding to my own post...

I discovered that if I "Print to PDF" from within Word, the page numbering
is correct. It is only if I first go to Acrobat Pro, then create a .PDF from
multiple docs that I get the problem.

This is not the first time I've gotten different results from converting
within Pro vs. printing to it...



Hans said:
Hello,

Here is the page, via MVPS' FAQ on Tables, Fields, & Forms, from which I got
the field coding:

http://word.mvps.org/FAQs/TblsFldsFms/InsEvnPgEndChap.htm

Note that I could not get it to work as written -- I had to add a space
between the word "IF" and the curly bracket to the right (see link above).

Thanks for your assistance,

-Hans


macropod said:
Hi Hans,

That may depend on how you're adding the extra page. For example, one might do it through vba or via field coding. Perhaps if you
post the code you're using, a solution can be suggested.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Hans said:
I have set up several hundred Word docs with some code I got on the 'net (via
this forum) that automatically determines if the doc ends on an odd or even
page, then, if odd, adds a page and the text "This page intentionally left
blank."

When I convert the docs using Acrobat Pro, if the doc naturally has an even
number of pages, say, four, then the "Page # of #" in the footer is incorrect
when converted to PDF, i.e., it the Total Pages digit is too high by one,
e.g., "Page 4 of 5." It's as if Word is suppressing a last page because it's
odd-numbered when viewed from within Word (and when a hard-copy is printed),
but it is not suppressed when distilled to PDF.

Is there a solution to this other than nixing the "Page # of #" format?

Thanks!
 
M

macropod

Hi Hans,

I'd use a slightly different field code to create the intentional page break:
{IF{=MOD({PAGE},2)}= 1 "{QUOTE 12 "This page intentionally left blank"}}
or
{IF{=MOD({PAGE},2)}= 0 "{QUOTE 12 "This page intentionally left blank"}}
depending on whether you want an odd or even page, but the results would be much the same.

As you've noted, "Print to PDF" from within Word,works correctly, but combining multiple files to create the PDF from Acrobat Pro
doesn't. I think you'll find, though, that using the Adobe 'Create PDF' button from within Word will also work correctly. This gives
you the choice of first creating the PDF from the Word document before using the PDF thus created as one of the files to be combined
via Acrobat Pro, or combining all the files in Word (eg via INCLUDETEXT, INCLUDEPICTURE & LINK fields) beforehand.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Hans said:
Hello,

Here is the page, via MVPS' FAQ on Tables, Fields, & Forms, from which I got
the field coding:

http://word.mvps.org/FAQs/TblsFldsFms/InsEvnPgEndChap.htm

Note that I could not get it to work as written -- I had to add a space
between the word "IF" and the curly bracket to the right (see link above).

Thanks for your assistance,

-Hans


macropod said:
Hi Hans,

That may depend on how you're adding the extra page. For example, one might do it through vba or via field coding. Perhaps if you
post the code you're using, a solution can be suggested.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Hans said:
I have set up several hundred Word docs with some code I got on the 'net (via
this forum) that automatically determines if the doc ends on an odd or even
page, then, if odd, adds a page and the text "This page intentionally left
blank."

When I convert the docs using Acrobat Pro, if the doc naturally has an even
number of pages, say, four, then the "Page # of #" in the footer is incorrect
when converted to PDF, i.e., it the Total Pages digit is too high by one,
e.g., "Page 4 of 5." It's as if Word is suppressing a last page because it's
odd-numbered when viewed from within Word (and when a hard-copy is printed),
but it is not suppressed when distilled to PDF.

Is there a solution to this other than nixing the "Page # of #" format?

Thanks!
 
H

Hans

I will give your code a try. I really should get a book on VB and read up...

Thanks again for your help!

-Hans

macropod said:
Hi Hans,

I'd use a slightly different field code to create the intentional page break:
{IF{=MOD({PAGE},2)}= 1 "{QUOTE 12 "This page intentionally left blank"}}
or
{IF{=MOD({PAGE},2)}= 0 "{QUOTE 12 "This page intentionally left blank"}}
depending on whether you want an odd or even page, but the results would be much the same.

As you've noted, "Print to PDF" from within Word,works correctly, but combining multiple files to create the PDF from Acrobat Pro
doesn't. I think you'll find, though, that using the Adobe 'Create PDF' button from within Word will also work correctly. This gives
you the choice of first creating the PDF from the Word document before using the PDF thus created as one of the files to be combined
via Acrobat Pro, or combining all the files in Word (eg via INCLUDETEXT, INCLUDEPICTURE & LINK fields) beforehand.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Hans said:
Hello,

Here is the page, via MVPS' FAQ on Tables, Fields, & Forms, from which I got
the field coding:

http://word.mvps.org/FAQs/TblsFldsFms/InsEvnPgEndChap.htm

Note that I could not get it to work as written -- I had to add a space
between the word "IF" and the curly bracket to the right (see link above).

Thanks for your assistance,

-Hans


macropod said:
Hi Hans,

That may depend on how you're adding the extra page. For example, one might do it through vba or via field coding. Perhaps if you
post the code you're using, a solution can be suggested.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

I have set up several hundred Word docs with some code I got on the 'net (via
this forum) that automatically determines if the doc ends on an odd or even
page, then, if odd, adds a page and the text "This page intentionally left
blank."

When I convert the docs using Acrobat Pro, if the doc naturally has an even
number of pages, say, four, then the "Page # of #" in the footer is incorrect
when converted to PDF, i.e., it the Total Pages digit is too high by one,
e.g., "Page 4 of 5." It's as if Word is suppressing a last page because it's
odd-numbered when viewed from within Word (and when a hard-copy is printed),
but it is not suppressed when distilled to PDF.

Is there a solution to this other than nixing the "Page # of #" format?

Thanks!
 
M

macropod

Hi Hans,

This isn't vb/vba - it's field coding.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Hans said:
I will give your code a try. I really should get a book on VB and read up...

Thanks again for your help!

-Hans

macropod said:
Hi Hans,

I'd use a slightly different field code to create the intentional page break:
{IF{=MOD({PAGE},2)}= 1 "{QUOTE 12 "This page intentionally left blank"}}
or
{IF{=MOD({PAGE},2)}= 0 "{QUOTE 12 "This page intentionally left blank"}}
depending on whether you want an odd or even page, but the results would be much the same.

As you've noted, "Print to PDF" from within Word,works correctly, but combining multiple files to create the PDF from Acrobat Pro
doesn't. I think you'll find, though, that using the Adobe 'Create PDF' button from within Word will also work correctly. This
gives
you the choice of first creating the PDF from the Word document before using the PDF thus created as one of the files to be
combined
via Acrobat Pro, or combining all the files in Word (eg via INCLUDETEXT, INCLUDEPICTURE & LINK fields) beforehand.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

Hans said:
Hello,

Here is the page, via MVPS' FAQ on Tables, Fields, & Forms, from which I got
the field coding:

http://word.mvps.org/FAQs/TblsFldsFms/InsEvnPgEndChap.htm

Note that I could not get it to work as written -- I had to add a space
between the word "IF" and the curly bracket to the right (see link above).

Thanks for your assistance,

-Hans


:

Hi Hans,

That may depend on how you're adding the extra page. For example, one might do it through vba or via field coding. Perhaps if
you
post the code you're using, a solution can be suggested.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

I have set up several hundred Word docs with some code I got on the 'net (via
this forum) that automatically determines if the doc ends on an odd or even
page, then, if odd, adds a page and the text "This page intentionally left
blank."

When I convert the docs using Acrobat Pro, if the doc naturally has an even
number of pages, say, four, then the "Page # of #" in the footer is incorrect
when converted to PDF, i.e., it the Total Pages digit is too high by one,
e.g., "Page 4 of 5." It's as if Word is suppressing a last page because it's
odd-numbered when viewed from within Word (and when a hard-copy is printed),
but it is not suppressed when distilled to PDF.

Is there a solution to this other than nixing the "Page # of #" format?

Thanks!
 

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