Page 1 of 1

Report

PostPosted: Mon Mar 26, 2012 6:36 pm
by Alison Oliveira
hi all,

i want to print a sentence in the same total line, but if i use report procedures like:
After-break or before-break, the sentence is printed after the total line and before total line...

How i print this sentence in the same line of total line??
the code:
REPORT   RELAT1 LINESIZE 132 PRINTER RELAT DTLCTL EVERY SPACE 1 +
                                           SUMCTL HIAR           
SEQUENCE F53SEPLT F53SEREG                                       
CONTROL F53SEPLT                                                 
TITLE 1 +                                                       
 ' example test.'   
TITLE 2 +                                                       
 ' INformation'   
HEADING F01FCDIV ('DIV')                                     
HEADING F53SEPLT ('PLT')                                     
HEADING F53SEREG ('REG')                                   
HEADING F01FCSEC ('SECT')                                       
HEADING F53SENOM ('NAME')                                       
HEADING DATAOP   ('OPCAO')                                     
HEADING F53SEOP1 ('MOD. 1')                                 
HEADING PREMIO   ('AWARD')                                 
HEADING DATANASC ('NASCTO')                                 
HEADING F53SECPF ('CPF')                                     
HEADING F01FCCAF ('COD.AFAST')                               
HEADING DATA-AFAST ('DTA.AFAST')                             
LINE 1 F01FCDIV F53SEPLT F53SEREG F01FCSEC F53SENOM DATAOP +
       F53SEOP1 PREMIO  DATANASC F53SECPF F01FCCAF DATA-AFAST
AFTER-BREAK. PROC                                           
 IF LEVEL EQ 1                                               
         DISPLAY ' TOTAL AWARDS OF PLANT  ' F53SEPLT ':'
 END-IF                                                     
 IF LEVEL EQ 2                                               
         DISPLAY 'TOTAL AWARDS: '                 
 END-IF                                                     
END-PROC


The result:

            21                                             2615,98                   
   TOTAL AWARDS OF PLANT  21:                                       
 0                                                               269567,90
  TOTAL AWARDS :                                       


but i want:
TOTAL AWARDS OF PLANT 21: 2615,98
TOTAL AWARDS : 269567,90


thanks all help!

Re: Report

PostPosted: Mon Mar 26, 2012 6:59 pm
by BillyBoyo
Then turn off Easytrieve's automatic printing for that LEVEL, and do the whole total line yourself.

Re: Report

PostPosted: Mon Mar 26, 2012 9:53 pm
by Alison Oliveira
How can i do that??... with the statement "NOPRINT" only totals of page is omitted... and how can i do to dont print the value in TOTAL AWARDS???

Re: Report

PostPosted: Mon Mar 26, 2012 10:21 pm
by BillyBoyo
If you do CONTROL F53SEPLT NOPRINT, Easytrieve will do everything it normal does for control-break processing, but will no print the total line. You then, in either a BEFORE-BREAK or AFTER-BREAK procedure, do all the DISPLAY that you want. If you mention file fields in the DISPLAY, the value used will be the total for that field at that level of break,

It also looks like you want "total totals".

CONTROL F53SEPLT NOPRINT FINAL

That will get Easytrieve printing the FINAL totals

CONTROL F53SEPLT NOPRINT NOPRINT

That will get Easytrieve processing FINAL totals, allowing you to deal with them in the report procedure with the LEVEL test that you have.

Re: Report

PostPosted: Mon Mar 26, 2012 10:28 pm
by Alison Oliveira
before you answer i get it!!!
CONTROL FINAL NOPRINT F53SEPLT NOPRINT

this is the correct statement!!!
this works

Re: Report

PostPosted: Mon Mar 26, 2012 10:28 pm
by Alison Oliveira
Thanks for help!!

Re: Report

PostPosted: Mon Mar 26, 2012 10:43 pm
by BillyBoyo
Well done. Thanks for letting us know.