cancel
Showing results for 
Search instead for 
Did you mean: 

Duplex Terms & Conditions with Groups and multiple varied pages per group

theresa_campbell
Explorer
0 Kudos

I've been searching for three weeks and have tried many combinations.

I have an existing purchase order that groups on a field called REFNUM.

The grouping and paging along with "Page N of M" has been working fine.

Now the customer requested that Terms and Conditions (T&C)  print on the back of every page (so every EVEN page).

I have gotten closest by putting the T&C in the Page Header, with conditional suppression of odd pages and even pages.

I have reviewed other posts so I know I am not the only one trying to do this?

The problem I now have is getting the "Page N of M" to behave properly.

I can get the PO to print "REFNUM (Continued)" on any of the follow-on ODD pages for a given group.

To do that I am using a formula called @REFNUMSUFFIX (and appending it to the REFNUM field in a text box on GH1)

WhilePrintingRecords;

StringVAR MyPage;

IF NOT OnFirstRecord

THEN MyPage:="Continued";

IF PREVIOUS({Command.REFNUM})={Command.REFNUM}

THEN

"-" & MyPage

Else ""

I tried the following to get a page # for that group, but it is not behaving as I want it to - it seems to be using boolean logic and giving me either a 1 or a 0 instead of a number:

WhilePrintingRecords;

NumberVar MyPage;

IF OnFirstRecord

THEN MyPage:= 1

ELSE

IF PREVIOUS({Command.REFNUM})={Command.REFNUM}

THEN

MyPage:= MyPage+1;

"-" & ToText((int(MyPage/2))-0)

Please let me know if you need more information.

Accepted Solutions (0)

Answers (2)

Answers (2)

theresa_campbell
Explorer
0 Kudos

FYI - the running total field in the upper left corner in red was constructed using these directions:


1:select the running total field from the Field Explorer.

2:In the 'Field to summarize' select the field which you want to summarize.

3:In the 'Type Of Summary' select count

4:In 'Evalute' select for each record

5: select Never on 'Reset'


Thanks to

Crystal Report Help:Tutorial , Question-Answer , Interview Material: How to reset Record number ever...

abhilash_kumar
Active Contributor
0 Kudos

Hi Theresa,

I'm sorry, I'm a little lost here! How do you want the Page Numbers to behave?

-Abhilash

theresa_campbell
Explorer
0 Kudos

Hi Abhilash,

Thank you for your attention to this matter.

Ideally, I want the page #s to reset after each group, and I would like to be able to display "Page n of m" at the top of each odd page in that header. Is it possible?

abhilash_kumar
Active Contributor
0 Kudos

So, for PO# 601517 (second and third screenshots) the first page would say Page 1 of 2 and the third page - the page after the terms and conditions would be Page 2 of 2?

-Abhilash

theresa_campbell
Explorer
0 Kudos

Yes, exactly, bearing in mind that the POs vary in the # of pages and the details within vary from Purchase order to purchase order - some may have 6 lines of detail; others may only have one; and there can be 100s of items on any given purchase order.

Message was edited by: Theresa Campbell

abhilash_kumar
Active Contributor
0 Kudos

Hi Theresa,

Does the Page N of M reset for each group?

Do you have a screenshot of what's happening please?

-Abhilash

theresa_campbell
Explorer
0 Kudos

The Page N of M does not reset for each group when using special fields.  Below is the image of the "single page" sample. The text in red is the Page N of M special field.  The other single digit under the logo in the upper left is a running total field on each refnum.

Next is pages three and four, in this case, a two page purchase order - these are the first page with the backer:

And this is the rest of the 2nd PO: