Modifications to custreports.4gl

The MAIN program block has been modified to open a window containing the form with a PROGRESSBAR and a MENU, to allow the user to start the report and to exit. A new function, cust_report, is added for interruption handling. The report definition, the cust_list REPORT block, remains the same as in the previous example.

Changes to the MAIN program block (custreport2.4gl):
01 MAIN
02
03   DEFER INTERRUPT
04   CONNECT TO "custdemo"
05   CLOSE WINDOW SCREEN
06   OPEN WINDOW w3 WITH FORM "reportprog"
07
08   MENU "Reports"
09   ON ACTION start 
10      MESSAGE "Report starting"
11       CALL cust_report()
12   ON ACTION exit 
13       EXIT MENU
14   END MENU
15
16   CLOSE WINDOW w3
17   DISCONNECT CURRENT
18
19 END MAIN
Note: