JavaScript Editor js editor     Web development 

Main Page

ReportListener objects provide object assistance to REPORT FORM and LABEL FORM commands. As the Report Engine processes your report or label data and layout, it sends information to a ReportListener object, rather than sending the output to a printer or preview device directly. The ReportListener "listens" for these instructions and handles the responsibility of evaluating and rendering the content of your report appropriately for your output device.

The ReportListener class is specifically designed for two-way communication with the Report Engine throughout the output generation process. Using a ReportListener, you can:



Visual FoxPro gives you several different ways to attach a ReportListener to REPORT FORM or LABEL FORM commands:

  • Use the OBJECT clause on the command. For more information, see REPORT FORM Command.

  • Use the OBJECT TYPE <N> clause, specifying a numeric ListenerType for the type of output you would like to create. The Report Engine requests a ReportListener of the appropriate ListenerType from the Report Output Application. For more information, see ListenerType Property and Report Output Application.

  • Use SET REPORTBEHAVIOR 90 to enable object assistance on all REPORT FORM and LABEL FORM commands. For more information, see SET REPORTBEHAVIOR Command.

Using ReportListeners, you can send output to multiple output devices in one report run, and you can add output types, such as HTML, that Visual FoxPro reports do not support natively. For more information, see ReportListener Foundation Classes and Extending Reports at Run Time.

See Also

JavaScript Editor js editor     Web development