Skip to Content
Former Member
Jun 27, 2014 at 10:01 PM

jsf reportPageViewer displays blank


Hi there,

For the last week I've been struggling to try to implement a crystal report viewer in my jsf webapp.

My environment is crystal reports 2011 processing server and report application server 2011, and the version of BO is SAP BusinessObjects Enterprise XI 4.0

The implementation of jsf being used is sun faces 2.2.5.

At one point I was able to get my project error-free, but it resulted in just a blank page (other than other html output).

In reading through the xi4_rasjava_dg_en developer guide, I know i need to

  • 1.Copy the required JAR files into your web application.
  • 2.Deploy the CrystalReports.war file with your web application.
  • 3.Edit your web.xml file.

1. I have the appropriate com.crystaldecisions jars (which are imported via maven dependency declarations),

2. I can't seem to find the crystalreports.war (the dev guide said \Program Files\Business Objects\BusinessObjects Enterprise 12.0\java\applications on Windows). My local installation doesn't have a java folder, and I'm told that the serverside installation does have a java folder but doesn't have any war files.

3. My web.xml looks like this:

        <servlet-name>Faces Servlet</servlet-name>
        <description>State saving method: 'client' or 'server' (=default). See JSF Specification 2.5.2</description>

There is also mention of a crystalreportviewers folder to be placed parallel to the WEB-INF folder, but I haven't figured out what it is for, other than "contains the support files required by the viewers." It does seem to be referenced as the crystal_image_uri though.

My JSF xhtml file contains this:

    <!--ui:include src="header.xhtml" /-->
        <h:form id="viewerForm">
            <bocrv:reportPageViewer viewerName="CrystalViewer"
            enablePageToGrow="false" height="540"
            zoomPercentage="100" width="750"
    <!--ui:include src="footer.xhtml" /-->

And the backing bean includes:

public Reports() throws IOException, SDKException

    IReportSource getManagedReportSource(String reportName) throws SDKException, IOException
    {"username: hhrpt, password: handheld, CMS: berlin-b, service: secEnterprise");
        IEnterpriseSession enterpriseSession = CrystalEnterprise.getSessionMgr().logon("username", "pass", "server", "secEnterprise");
        IReportSourceFactory reportSourceFactory = (IReportSourceFactory) enterpriseSession.getService("", "PSReportFactory");

        IInfoStore infostore = (IInfoStore) enterpriseSession.getService("InfoStore");
        IInfoObjects reports = infostore.query("Select SI_ID, SI_CUID From CI_INFOOBJECTS Where SI_NAME='" + reportName + "' And SI_INSTANCE=0");
        IInfoObject report = (IInfoObject)reports.get(0);
"CUID of report: " + report.getCUID());
        String reportID = "cecuid:///" + report.getCUID() + "";
        IReportSource reportSource = reportSourceFactory.openReportSource(reportID, java.util.Locale.ENGLISH);

        if(reportSource != null)
  "report source found");
        return reportSource;

which at one point i was able to see successfully get the CIUD and the reportsource.

However, I'm thinking my main problem might be not having a CrystalReports.war....if I can't seem to locate it, where else should I be able to get it?

Is there anything else I'm clearly doing wrong? It seems difficult to find information or examples on successful implementations of a crystal report viewer in a jsf webapp.