Crystal Reports

Crystal Reports

This guild will show you how to set up and run your Crystal Reports in WebClient.

Download article files here

Plex Setup

All the Plex objects that you will need are in the WebClient Components group model.

"_CrystalReportsXI.UI.ViewCrystalReportFull" is the function that you will want to used or inherit from. This function works by inputting the report name. The function will open the Crystal report object and show/hide the correct field types as needed on the panel. The report parameters can be passed in or entered on the panel directly.   The "View PDF" button will output the PDF of the report. The "Export" button will open the report in the Crystal Report Web Viewer.

Eclipse/Workspace Setup

1) Please download and install the Crystal Report for Eclipse Plugin. You can find all the files and instructions that you need at this site:
http://www.businessobjects.com/campaigns/forms/downloads/crystal/eclipse/datasave.asp

2) Copy the attached CRConfig.xml file to the same directory as your webclient.properties file.

Do not change the entry for <Xreportlocation> value.  This is stubbed out and not used with Crystal Reports for WebClient.

To change the number of minutes that the session can be inactive before the report source and its resources are released, edit the <timeout> value.

A value of 0 indicates that there is no timeout.


  1. <timeout>0</timeout>


If your application uses User-defined Function Libraries (UFLs), edit the <ExternalFunctionLibraryClassNames> value by adding the fully-qualified names of each external function library class to an embedded <classname> tag.

  1. <ExternalFunctionLibraryClassNames>
  2.      <classname>com.mycompany.myufls.UFL1</classname>
  3.      <classname>com.mycompany.myufls.UFL2</classname>
  4. </ExternalFunctionLibraryClassNames>


3) Add an entry to your obclient.properties file for Crystal.ReportPath. It should look something like this:Crystal.ReportPath=..\\..\\CrystalReports\\

Add a DataSource entry to the obclient.properties for "Environment.Default.CrystalDataSource=".  The value of this entry can be the same as your entry for "Environment.Default.DataSource="

The value represents a folder in WebContent where you will place your report files.
If you would like to use a different folder from outside of your workspace to store the report files, you can change it in the Plex code with these steps:

  1. In the function that inherits from "CrystalReportsXI.UI.ViewCrystalReportFull", go to "Post Point Process options".
  2. Set the value of "CrystalReportsL<PublishedPath>" to whatever folder you want on your WebServer.

You will also need to set up a data source for Crystal reports in the obclient. This will be similar to the data source that you already entered for your webclient application, but the entry tag will be "Environment.Default.CrystalDataSource".

4) Right Click your Java Project in Eclipse. Select Properties. Select Java Build Path. In the Libraries Tab, add the "Crystal Reports Java Project Runtime Library". Sometimes Eclipse will give an error and not allow you to reference the Crystal Report Library. You can work around this by adding references to all the Crystal Reports Jars in your Project instead.

5) Copy the attached "Src" folder to the same location as your Plex-generated Source code.

6) Copy the items in the attached "Templates" folder into your Custom Templates/Src folder.

7) Copy the items in the attached "WebContent" folder to the WebContent folder of your Web Project.

8) Copy the items in the attached "WEB-INF/lib" folder to the WEB-INF/lib folder of your Web Project.

9) To enable logging for Crystal Reports, please add the following entries to your Webclient.properties file.

NOTES:

For Crystal Reports that include charting some logging messages such as the following might display in the Eclipse Console:

log4j:WARN No appenders could be found for logger (com.businessobjects.visualization.pfjgraphics.rendering.converter.GraphLoader).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info. 

These are just warnings and will not affect the operation of WebClient or Crystal Reports.

To remove these messages you can:

1) Copy the log4j.xml file under the Java Web Project.java.resources.src and restart the web server 

2) Add the class (com.businessobjects.visualization.pfjgraphics.rendering.converter.GraphLoader) to the logging section of WebClient.report


    • Related Articles

    • Building Custom Reports / Diagrams in CM evolveIT

      Please look at the attached file(s)
    • CM evolveIT User Manual

      Welcome to CM evolveIT         User Training Manual                                                             Restrictive Rights This document and the product referenced in it are subject to the terms and conditions of the user License Agreement ...
    • Incident Reporter for Mobile

      Video Walkthrough Pattern Functions All functions will be under "Patterns.Mobile". CordovaPage This function inherits from ~WebShell, and has an IMPL Name of Cordova.  Any function inheriting from this will use the Cordova-page.ctrl template.  This ...
    • Incident Reporter for Web

      Video Walkthrough Pattern Functions All functions will be under "Patterns.Web". GoogleMap This pattern is a simple UIBasicShell.  It displays a single field: GoogleMap for GoogleMap.  This field has a Control Name of ...
    • Source Scanner for IBM JCL

      This document describes the entities and relations the JCL Scanner creates on encountering various JCL code constructs. Current output Structures Jobs Procedures (cataloged and in-stream) JobSteps(EXEC) Properties File-levelmetrics Procedure default ...