Tim, here is an extract from STE printout of the report.

I left in most of the printer control strings in case any of them is 
interfering.

 

 

REPORT.BASED.ON.PANEL:23 

NAME:~07/2019~

REPORT.MODE:WP

OUTPUT.FILENAME:~NUL~

CREATE.DISK.FILE

REPORT.INDEX: 3 

TEXT.LINES=65 TOP.MARGIN=0 BOTTOM.MARGIN=0 LEFT.MARGIN=0 

BACKWARD

REPORT.FORM:

FIRST.PAGE.HEADER

DO.LOOKUP

PROMPT.FOR.VALUE.OF.RV:250 USING.FORMAT:~U1~

  PROMPT.MSG:~Print to Paper? [Y] if Yes or [ENTER] to PDF:~

SET.RV:251 FORMULA:

~if RV250="Y" then cat.c["c:\dpspool\";apply.format["G999";today - 
date[1;1;year[today]] + 1];apply.format["G99999";now];".{1}"] else~ 

 CR

~cat.c["c:\dpspool\";apply.format["G999999";~  FIELD=P23F1 

~];apply.format["G99";~  FIELD=P23F2 ~];".{2}"] endif~ 

FORMULA.END;

TURN.FILE.OFF

BEGIN.WRITING.TO.FILENAME.IN.RV:251

TURN.FILE.ON

OTHER.PAGE.HEADER

TWO.LEVEL.REPORT.HEADER

REPORT.BODY

TURN.FILE.OFF

SUBREPORT.THRU.DOOR:5 TO.PANEL:24

FIRST.PAGE.HEADER

SET.RV:19 FORMULA:~1~ 

FORMULA.END;

PRINT.CNTRL.STRING: 206 0 13 206 

PRINT.CNTRL.STRING: 192 0 0 5 8 192 

PRINT.CNTRL.STRING: 250 112 58 92 109 117 111 109 97 92 109 117 108 111 103 105 
110 118 46 106 112 103 59 53 46 50 53 59 48 46 52 59 50 46 53 59 48 46 55 53 
250 

PRINT.CNTRL.STRING: 244 70 76 117 99 105 100 97 32 83 97 110 115 32 85 110 105 
99 111 100 101 244 

PRINT.CNTRL.STRING: 244 80 49 48 244 

PRINT.CNTRL.STRING: 244 87 50 57 244 

PRINT.CNTRL.STRING: 244 83 87 244 

TAB.TO.COL:9 

OTHER.PAGE.HEADER

SET.RV:19 FORMULA:~RV19+1~ 

FORMULA.END;

PRINT.CNTRL.STRING: 206 0 13 206 

PRINT.CNTRL.STRING: 192 0 0 5 8 192 

PRINT.CNTRL.STRING: 250 112 58 92 109 117 111 109 97 92 109 117 108 111 103 105 
110 118 46 106 112 103 59 53 46 50 53 59 48 46 52 59 50 46 53 59 48 46 55 53 
250 

PRINT.CNTRL.STRING: 244 70 76 117 99 105 100 97 32 83 97 110 115 32 85 110 105 
99 111 100 101 244 

PRINT.CNTRL.STRING: 244 80 49 48 244 

PRINT.CNTRL.STRING: 244 87 50 57 244 

PRINT.CNTRL.STRING: 244 83 87 244 

TAB.TO.COL:9 

TWO.LEVEL.REPORT.HEADER

REPORT.BODY

PRINT.CNTRL.STRING: 244 70 77 83 32 80 71 111 116 104 105 99 244 

PRINT.CNTRL.STRING: 244 80 49 48 244 

PRINT.CNTRL.STRING: 244 87 52 53 244 

PRINT.CNTRL.STRING: 244 83 87 244  CR

TWO.LEVEL.FOOTER

PAGE.FOOTER

SKIP.TO.PAGE.BOTTOM

RV:4;~A16~ ~ ~ RV:6;~DZ9/99/99~ 

FINAL.FOOTER

SKIP.TO.PAGE.BOTTOM

RV:4;~A16~ ~ ~ RV:6;~DZ9/99/99~ 

END.SUBREPORT.FOR.PANEL:24

SET.PAGE.NUMBER.TO:1

TURN.FILE.ON

SUBREPORT.THRU.DOOR:5 TO.PANEL:24

FIRST.PAGE.HEADER

PRINT.CNTRL.STRING: 206 0 13 206 

PRINT.CNTRL.STRING: 192 0 0 5 8 192 

PRINT.CNTRL.STRING: 250 112 58 92 109 117 111 109 97 92 109 117 108 111 103 105 
110 118 46 106 112 103 59 53 46 50 53 59 48 46 52 59 50 46 53 59 48 46 55 53 
250 

PRINT.CNTRL.STRING: 244 70 76 117 99 105 100 97 32 83 97 110 115 32 85 110 105 
99 111 100 101 244 

PRINT.CNTRL.STRING: 244 80 49 48 244 

PRINT.CNTRL.STRING: 244 87 50 57 244 

PRINT.CNTRL.STRING: 244 83 87 244 

TAB.TO.COL:9 

OTHER.PAGE.HEADER

PRINT.CNTRL.STRING: 206 0 13 206 

PRINT.CNTRL.STRING: 192 0 0 5 8 192 

PRINT.CNTRL.STRING: 250 112 58 92 109 117 111 109 97 92 109 117 108 111 103 105 
110 118 46 106 112 103 59 53 46 50 53 59 48 46 52 59 50 46 53 59 48 46 55 53 
250 

PRINT.CNTRL.STRING: 244 70 76 117 99 105 100 97 32 83 97 110 115 32 85 110 105 
99 111 100 101 244 

PRINT.CNTRL.STRING: 244 80 49 48 244 

PRINT.CNTRL.STRING: 244 87 50 57 244 

PRINT.CNTRL.STRING: 244 83 87 244 

TAB.TO.COL:9 

TWO.LEVEL.REPORT.HEADER

REPORT.BODY

PRINT.CNTRL.STRING: 244 70 77 83 32 80 71 111 116 104 105 99 244 

PRINT.CNTRL.STRING: 244 80 49 48 244 

PRINT.CNTRL.STRING: 244 87 52 53 244 

PRINT.CNTRL.STRING: 244 83 87 244  CR

TWO.LEVEL.FOOTER

PAGE.FOOTER

SKIP.TO.PAGE.BOTTOM

RV:4;~A16~ ~ ~ RV:6;~DZ9/99/99~ 

FINAL.FOOTER

SKIP.TO.PAGE.BOTTOM

RV:4;~A16~ ~ ~ RV:6;~DZ9/99/99~ 

END.SUBREPORT.FOR.PANEL:24

STORE.RV: 7 IN.FIELD:34

STORE.RV: 8 IN.FIELD:40

DO.LOOKUP

TWO.LEVEL.FOOTER

PAGE.FOOTER

FINAL.FOOTER

SKIP.TO.PAGE.BOTTOM

EJECT

REPORT.END;

 

 

 

 

From: Ed Marfil, MAST UNITED [mailto:[email protected]] 
Sent: Wednesday, July 24, 2019 1:04 PM
To: '[email protected]' <[email protected]>
Subject: RE: [Dataperf] How to print Total page count in report.

 

Hi Tim,

Yup, same way you have it.  I used the example Ralph Alvy had in his book about 
keeping record count of males / females.

After much experimentation, I’ve found the problem;

If I have the “Turn File Off” the RV counter only adds the value 1 on the first 
additional page, ignoring additional pages.

If I do not add “Turn File Off”, then the RV counter works and adds each 
additional page.

Unfortunately, this puts me back to the report actually printing twice.

Yes, DP generates page break natively. I have the text lines value at 65.

Ed.

 

 

From: Dataperf [mailto:[email protected]] On Behalf Of Tim Rude
Sent: Wednesday, July 24, 2019 7:08 AM
To: [email protected] <mailto:[email protected]> 
Subject: Re: [Dataperf] How to print Total page count in report.

 

Hmm. Do your report structure and formulas look something like this? (I left 
out non-relevant sections.)

---REPORT BODY---
   ---Turn File Off---
   ===SUBREPORT LINK/PANEL: 0 1 ===
      ---FIRST PAGE HEADER---
         ---Store Value in Report Variable 1 ---  [Formula: 1]
         Dummy page number line
      ---OTHER PAGE HEADER---
         ---Store Value in Report Variable 1 ---  [Formula: RV1+1]
         Dummy page number line
      ---REPORT BODY---
         Blah Blah Blah
   ===END OF SUBREPORT===
   ---Turn File On---
   ---Set Page Number To: 1 ---
   ===SUBREPORT LINK/PANEL: 0 1 ===
      ---FIRST PAGE HEADER---
      ---OTHER PAGE HEADER---
         ---Include Header Before Data---
         Page [PgNum GZZZZZ9;;B] of [RV1 GZZZZZ9;;B]
      ---REPORT BODY---
         Blah Blah Blah
   ===END OF SUBREPORT===
---TWO-LEVEL FOOTER---

Also, are the page breaks being generated by DP natively because of your Report 
Settings item 7 Text Lines value?

Tim Rude

On 7/23/2019 5:40 PM, Ed Marfil, MAST UNITED wrote:

Hi Tim,

I spoke too soon about getting the page total working.  The RV in the Other 
Page Header to add 1 to the RV in the First Page Header only adds exactly 1 and 
does not keep adding on after page 2.  Thus even if there are more than 2 pages 
in the report, it counts total only 2.

Any suggestions?

Ed.

 

_______________________________________________
Dataperf mailing list
[email protected]
http://lists.dataperfect.nl/cgi-bin/mailman/listinfo/dataperf

Reply via email to