Userinitials and fileref on last page only.

J

Jan Kronsell

Hi

Im trying to put userinitials and filename on the last page of a document
only. Pagenumbers are set to start with 0, and pagenumbers are not shown on
forst page. I have put a bookmark on the last page and uses this:

{ IF { PAGE \* MEGEFORMAT} ={PAGEREF MYBOOK \* MERGEFORMAT} {USERINITIALS
\* MERGEFORMAT} / {FILENAME \*MERGEFORMAT} }

but it appears blank on all pages.

Jan
 
G

Graham Mayor

Did you put the bookmark on the last page and not in the header/footer?
Did you update the fields? - Updating fields in the header is a pain - use
the sample macro at http://www.gmayor.com/installing_macro.htm
You need quotes around the result fields or you will get the slash on all
pages and the initials on the last page.
The Mergeformat switches even if spelled correctly are superfluous.

{ IF { PAGE } = { PAGEREF MYBOOK } "{ USERINITIALS } / { FILENAME }" }

The following should work also.

{ IF { PAGE } = { NUMPAGES } "{ USERINITIALS } / { FILENAME }" }

--
<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
Graham Mayor - Word MVP


<>>< ><<> ><<> <>>< ><<> <>>< <>><<>
 
T

Terry Farrell

As Graham points out, there's no need for a bookmark. The final page is
(nearly) always equal to the NUMPAGES so simply use the PAGES=NUMPAGES to
construct the IF argument.
 
J

Jan Kronsell

In this case lastpage is not equal to numpages, which causes the problem in
the first place.
But I'll try Grahams solution a little later on.

Jan
 
S

Suzanne S. Barnhill

If the page really is the *last* page, then it will be the same as NUMPAGES
regardless of what page numbers appear on the pages.
 
J

Jan Kronsell

This is my original fields

{IF {PAGE} = {NUMPAGES} "{USERINITIALS} / [FILENAME}"}

and it works perfectly allright until I format pagenumbering to start with 0
in stead of 1. Then all pages in the document appears blank. And if I show
values in stead of fieldcodes on the last page it says

{IF 4 = 5 "{USERINITIALS} / [FILENAME}"}

Jan
 
J

Jan Kronsell

But now I got it to work using

IF {PAGE} = {PAGEREF MYBOOK} "{USERINITIALS} / [FILENAME}"}

and placing a bookmark on the bottom of the last page.

So thank yopu for your effort everybody.

Jan

Jan said:
This is my original fields

{IF {PAGE} = {NUMPAGES} "{USERINITIALS} / [FILENAME}"}

and it works perfectly allright until I format pagenumbering to start
with 0 in stead of 1. Then all pages in the document appears blank.
And if I show values in stead of fieldcodes on the last page it says

{IF 4 = 5 "{USERINITIALS} / [FILENAME}"}

Jan


If the page really is the *last* page, then it will be the same as
NUMPAGES regardless of what page numbers appear on the pages.
 
T

Terry Farrell

If you started numbering from zero, all you need to do is edit the field to
PAGE = NUMPAGES-1 and it will work.

Terry

Jan Kronsell said:
But now I got it to work using

IF {PAGE} = {PAGEREF MYBOOK} "{USERINITIALS} / [FILENAME}"}

and placing a bookmark on the bottom of the last page.

So thank yopu for your effort everybody.

Jan

Jan said:
This is my original fields

{IF {PAGE} = {NUMPAGES} "{USERINITIALS} / [FILENAME}"}

and it works perfectly allright until I format pagenumbering to start
with 0 in stead of 1. Then all pages in the document appears blank.
And if I show values in stead of fieldcodes on the last page it says

{IF 4 = 5 "{USERINITIALS} / [FILENAME}"}

Jan


If the page really is the *last* page, then it will be the same as
NUMPAGES regardless of what page numbers appear on the pages.


In this case lastpage is not equal to numpages, which causes the
problem in the first place.
But I'll try Grahams solution a little later on.

Jan

Terry Farrell wrote:
As Graham points out, there's no need for a bookmark. The final
page is (nearly) always equal to the NUMPAGES so simply use the
PAGES=NUMPAGES to construct the IF argument.


Hi

Im trying to put userinitials and filename on the last page of a
document only. Pagenumbers are set to start with 0, and
pagenumbers are not shown on forst page. I have put a bookmark on
the last page and uses this: { IF { PAGE \* MEGEFORMAT} ={PAGEREF
MYBOOK \* MERGEFORMAT}
{USERINITIALS \* MERGEFORMAT} / {FILENAME \*MERGEFORMAT} }

but it appears blank on all pages.

Jan
 
J

Jan Kronsell

I know, but sometimes pangenumbering starts on page 3, sometimes on page 85,
sometimes.... And I don't know before I start thwe document, which it is.
The reason is, that everything before the body is on unnumberede pages, and
I never can say before the user starts to write, how much that will be.

Jan

Terry said:
If you started numbering from zero, all you need to do is edit the
field to PAGE = NUMPAGES-1 and it will work.

Terry

Jan Kronsell said:
But now I got it to work using

IF {PAGE} = {PAGEREF MYBOOK} "{USERINITIALS} / [FILENAME}"}

and placing a bookmark on the bottom of the last page.

So thank yopu for your effort everybody.

Jan

Jan said:
This is my original fields

{IF {PAGE} = {NUMPAGES} "{USERINITIALS} / [FILENAME}"}

and it works perfectly allright until I format pagenumbering to
start with 0 in stead of 1. Then all pages in the document appears
blank. And if I show values in stead of fieldcodes on the last page
it says {IF 4 = 5 "{USERINITIALS} / [FILENAME}"}

Jan



Suzanne S. Barnhill wrote:
If the page really is the *last* page, then it will be the same as
NUMPAGES regardless of what page numbers appear on the pages.


In this case lastpage is not equal to numpages, which causes the
problem in the first place.
But I'll try Grahams solution a little later on.

Jan

Terry Farrell wrote:
As Graham points out, there's no need for a bookmark. The final
page is (nearly) always equal to the NUMPAGES so simply use the
PAGES=NUMPAGES to construct the IF argument.


message Hi

Im trying to put userinitials and filename on the last page of a
document only. Pagenumbers are set to start with 0, and
pagenumbers are not shown on forst page. I have put a bookmark
on the last page and uses this: { IF { PAGE \* MEGEFORMAT}
={PAGEREF MYBOOK \* MERGEFORMAT}
{USERINITIALS \* MERGEFORMAT} / {FILENAME \*MERGEFORMAT} }

but it appears blank on all pages.

Jan
 

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