- Code: Select all Expand view RUN
- #include "FiveWin.ch"
#include "Report.ch"
FUNCTION MAIN()
LOCAL oWnd
DEFINE WINDOW oWnd
ACTIVATE WINDOW oWnd;
ON INIT ( REPORTS(), oWnd:End() )
RETURN NIL
STATIC FUNCTION REPORTS()
LOCAL oPrn
PRINT oPrn PREVIEW
REP01( oPrn, "1" )
REP01( oPrn, "2" )
ENDPRINT
RETURN NIL
STATIC FUNCTION REP01( oPrn, cNum )
LOCAL oRpt
USE TEST
REPORT oRpt TITLE "TEST" + cNum TO DEVICE oPrn
COLUMN TITLE "St" DATA Test->State
COLUMN TITLE "First Name" DATA Test->First
COLUMN TITLE " Salary" DATA Test->Salary
END REPORT
oRpt:CellView()
ACTIVATE REPORT oRpt
CLOSE TEST
RETURN NIL
EMG