Hi All,

I have a problem with loading Crystal Reports(version 9) from JSP, I use Tomcat as my webserver.

<%@ page contentType="text/html; charset=UTF-8"%>
<%@ page import="java.util.*"%>
<%@ page import="java.awt.*"%>
<%@ page import="com.crystaldecisions.report.web.viewer.Cry stalReportViewer"%>
<%@ page import="com.crystaldecisions.report.web.viewer.*"% >
<%@ page import="com.crystaldecisions.sdk.occa.report.lib.* "%>
<%@ page import="com.crystaldecisions.reports.reportenginei nterface.JPEReportSourceFactory,com.crystaldecisio ns.sdk.occa.report.reportsource.IReportSourceFacto ry2,com.crystaldecisions.sdk.occa.report.reportsou rce.IReportSource" %>
<html>
<body>
<%
try{
String report = "report.rpt";
IReportSourceFactory2 rptSrcFactory = new JPEReportSourceFactory();
IReportSource reportSource = (IReportSource)rptSrcFactory.createReportSource(re port,request.getLocale());

CrystalReportViewer viewer = new CrystalReportViewer();
viewer.setReportSource(reportSource);
viewer.processHttpRequest(request,response,getServ letConfig().getServletContext(),out);
viewer.dispose();

}catch(Exception e){
out.println(e.getMessage());
}
%>
</body>
</html>

But when I run the jsp I get the following message or error in the browser:

com.crystaldecisions.report.web.viewer.CrystalRepo rtViewer
java.lang.NoSuchMethodError


I'm assuming that the line viewer.setReportSource(reportSource); is the one that the error message is pointing to, because i have tried removing this line, and the JSP worked successfully.

Please help me, if you know the solution. Thanks in advance.