Page 1 of 1

add text to REPORT

Posted: Mon Jun 02, 2008 3:08 pm
by MOISES
Hi,

I have a REPORT such as:

REPORT oReport TITLE OemToAnsi("*** Listado de AGENTES ***") ;
PREVIEW CAPTION OemToAnsi("Listado de AGENTES")


COLUMN TITLE OemToAnsi("C¢digo") DATA AGENTES->CODIGO

COLUMN TITLE "Nombre del Agente" DATA LEFT( AGENTES->NOMBRE, 30 )

END REPORT

ACTIVATE REPORT oReport


At the end of it (not as PAGE FOOTERS), I would like to add a table like this:


=====================
Resumen anual
====================
Total primer trimestre 100
====================
Total segundo trimestre 200
====================

¿How can be done?. Thank you!!!.

Best regards,

Re: add text to REPORT

Posted: Mon Jun 02, 2008 4:32 pm
by Enrico Maria Giordano

Code: Select all

#include "Fivewin.ch"
#include "Report.ch"


FUNCTION MAIN()

    LOCAL oRpt

    USE TEST

    REPORT oRpt PREVIEW

    COLUMN TITLE "LAST";
           DATA FIELD -> last

    COLUMN TITLE "FIRST";
           DATA FIELD -> first

    ENDREPORT

    ACTIVATE REPORT oRpt;
             ON END ( oRpt:TotalLine( RPT_DOUBLELINE ),;
                      oRpt:Say( 1, "This is the first line" ),;
                      oRpt:StartLine(),;
                      oRpt:EndLine(),;
                      oRpt:Say( 1, "This is the second line" ) )

    CLOSE

    RETURN NIL
EMG

Posted: Mon Jun 02, 2008 8:01 pm
by MOISES
Thank you!!!