Enabling Report Listener in AccountMate 7 for LAN

December 2008

 

Introduction

Microsoft has opened the report architecture in Visual FoxPro 9.0. A new ReportListener base class allows developers to create their own customized report output. Several companies have developed Report Listener products to integrate with existing VFP-based applications.

AccountMate has developed Report Listener program hooks for its reporting engine in the latest AccountMate 7 for LAN (AM7 for LAN) product. The design does not restrict AccountMate users to a particular Report Listener product. This also allows AccountMate Solutions Providers to develop a new Report Listener to work with AM7 for LAN.

This document discusses how to enable Report Listener in AM7 for LAN. As an example, it describes the steps to download and install XFRX Report Listener from the AccountMate website and to enable XFRX within AM7 for LAN.

Note: AccountMate has the license to distribute XFRX Library, so end users on AccountMate 7 for LAN do not need to purchase a separate license to use XFRX Library together with AM7 for LAN.

Supported Report Listener

The Report Listener program hooks in AM7 for LAN have been tested to be compatible with the third-party Report Listener XFRX by Eqeus.com (www.eqeus.com).

Other Reading Materials

You may refer to the following articles from the Microsoft website for more information on how Report Listener works in Visual FoxPro 9.0.

§         Listening to a Report

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnfoxtk05/html/ft05b6.asp

§         Visual FoxPro Report Writer in Action

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnfoxgen9/html/VFP9Reports2.asp

§         What’s New in the Visual FoxPro 9.0 Report Writer

http://msdn.microsoft.com/en-us/library/ms965279.aspx 

§         Report Output Application

http://msdn.microsoft.com/en-us/library/ms952577(VS.80).aspx

§         How to generate and then e-mail a report by using Visual FoxPro 9.0

http://support.microsoft.com/default.aspx?scid=kb;en-us;895277

Downloading and Installing XFRX Report Listener

Perform the following steps to download and install the XFRX Report Listener.

1.      Access the AccountMate Download Center website at www.accountmate.com/download.

2.      Select the link for Software Updates for Service Plan Subscribers; then, provide your Support ID, password and e-mail address in order to access the page.

Note: The Support ID and password information is used to validate whether you have an active maintenance plan for your AccountMate product.

3.      Select to download the XFRX Report Listener. The XFRX Report Listener Library will be saved to your computer as AMLAN7_XFRX.zip.

4.      Extract the following library files from the downloaded ZIP file into the root directory of your AM7 for LAN application. These files do not need to be registered.

5.      The XFRX Report Listener provides report preview, export, and e-mail capabilities. Refer to the following subtopics on how to enable XFRX for report export and e-mail and report preview.

Enabling XFRX for Report Export and E-mail

Perform the following steps to enable XFRX for report export and e-mail.

1.      Add or amend records in Amrlis.dbf.

a.      Extract the Amrlis.dbf from the downloaded ZIP file to the AM7 for LAN application folder.

b.      Open the Amrlis.dbf file and check the available output formats. If you choose not to activate all the output formats, delete the corresponding records.

c.      Note that each output option calls a user-defined function “XFRXListener”, which will be implemented in step 2 below.

d.      The AccountMate report interface form will display different output formats for the Export and Email options based on the records in Amrlis.dbf.

2.      Extract the xfrxlistener.FXP and xfrxlistener.prg from the downloaded ZIP file to the AM7 for LAN application folder.

3.      Run any report in AM7 for LAN; then, click the Export or Email button on the report form toolbar. A selection of different output format options will be displayed. Clicking any of those options will export or e-mail the report in the selected format.

Enabling XFRX for Report Preview

Perform the following steps to enable XFRX for report preview.

1.      Extract the following files from the downloaded ZIP file into the root directory of the AM7 for LAN application.

2.      Open the amaddon.dbf file; then, access the BEFOREPRINTJOB function.

3.      Copy the following code to the BEFOREPRINTJOB function; then, change the owner to any value other than “AM”.

#INCLUDE "amlan.h"

*/ Using XFRX for report preview

if tcOutput = OUTPUT_TO_PREVIEW

   pcRptFunction = "XFRXListener(tcRptID, lcFrxName, tcOutput, '')"

endif

4.      Save your changes; then, close the amaddon.dbf file.

5.      Run any report in AM7 for LAN and click the Preview button on the report form toolbar. This will display the XFRX report preview window.


This information is provided "AS IS" without warranty of any kind. AccountMate Software Corporation (“AccountMate”) disclaims all warranties, either express or implied. In no event shall AccountMate be liable for any damages whatsoever including direct, indirect, incidental, consequential, loss of business profits, or special damages, even if AccountMate has been advised of the possibility of such damages.


Copyright © 1995-2008 AccountMate Software Corporation. All rights reserved.
Site MapLegal Notices and Terms of UsePrivacy StatementWebsite Feedback