hi all, Can anybody help me,

In my project, Im using Tomcat5 webserver and Oracle10g as backend.now I want to display one report .For that Im using CrystalReportsXi with JSP page , Report is generated correctly and displayed on to browser with out images.Images are those came with CrystalReport Tool.

Moreover I copied crystalreportviewer11 folder to my web application root folder.
below are my two JSP files

<%@page import="com.crystaldecisions.reports.sdk.*" %>
<%@page
import="com.crystaldecisions.sdk.occa.report.reportsource.*"
%>
<%@page import="com.crystaldecisions.sdk.occa.report.lib.*" %>
<%
String reportName = "Report1.rpt";
try
{
Object reportSource =
session.getAttribute("reportSource");
if (reportSource == null)
{

ReportClientDocument oReportClientDocument = new
ReportClientDocument();
oReportClientDocument.open(reportName, 0);
reportSource =
oReportClientDocument.getReportSource();
session.setAttribute("reportSource", reportSource);
}
response.sendRedirect("CrystalReportViewer.jsp");
}
catch(ReportSDKException e)
{
out.print(e);
}
%>


for Viewer:


<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>
<%@page import="com.crystaldecisions.report.web.viewer.*"%>
<%@page import="com.crystaldecisions.reports.sdk.*" %>
<%@page
import="com.crystaldecisions.sdk.occa.report.reportsource.*"
%>
<%
IReportSource reportSource =
(IReportSource)session.getAttribute("reportSource");
CrystalReportViewer oCrystalReportViewer = new
CrystalReportViewer();
oCrystalReportViewer.setReportSource(reportSource);
oCrystalReportViewer.setOwnPage(true);
oCrystalReportViewer.setOwnForm(true);
oCrystalReportViewer.setPrintMode(CrPrintMode.ACTIVEX);
if (session.getAttribute("refreshed") == null)
{
oCrystalReportViewer.refresh();
session.setAttribute("refreshed", "true");
}
oCrystalReportViewer.processHttpRequest(request, response,
getServletConfig().getServletContext(), null);
%>

can u sugest me any solution .

thanks in advance

Recommended Answers

All 2 Replies

There is also a forum for JSP here. We would have liked you searching a bit and getting to know the place before posting directly. Moreover it's much more beneficial for you if you put this question there as you would get help faster.

I found the answer. In cristalreport folder there is no images thats why i not able to view the images. Again i instaled CrystaleReport11 then it is working fine.
thank u

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.