The Artima Developer Community
Sponsored Link

Java Answers Forum
Problem in BIRT (Report ) when run in weblogic error is " org.mozil....l "

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
diwakar gupta

Posts: 2
Nickname: diwakar
Registered: Apr, 2006

Problem in BIRT (Report ) when run in weblogic error is " org.mozil....l " Posted: Apr 26, 2006 12:04 AM
Reply to this message Reply
Advertisement
hello everybody,
I am facing a problem In BIRT a reporting tool I am wrote one jsp for display a report in pdf formate on web.
when i run this jsp wblogic server gives a error ==
<u><b>"Org.mozilla.javascript.ImporterTopLevel.initStandardObjects( Lorg/mozilla/javascript/Context;Z)V "</b></u>I am using a weblogic server. I attech my jsp code also, plz help me if any one know the solution

<b>and error show in weblogic console is</b>

java.lang.NoSuchMethodError: org.mozilla.javascript.ImporterTopLevel.initStandar
dObjects(Lorg/mozilla/javas cript/Context;Z)V
at org.eclipse.birt.core.script.ScriptContext.<init>(ScriptContext.java:
81)
at org.eclipse.birt.report.engine.executor.ExecutionContext.<init>(Execu
tio nContext.java:248)
at org.eclipse.birt.report.engine.api.impl.EngineTask.<init>(EngineTask.
jav a:118)
at org.eclipse.birt.report.engine.api.impl.RunAndRenderTask.<init>(RunAn
dRe nderTask.java:54)
at org.eclipse.birt.report.engine.api.impl.ReportEngineHelper.createRunA
ndRenderT ask(ReportEngineHelper.java:215)
at org.eclipse.birt.report.engine.api.ReportEngine.createRunAndRenderTas
k(ReportE ngine.java:258)
at resources.jsp.Pdf.run(Pdf.java:81)
at jsp_servlet._resources._jsp.__test._jspService(Test.jsp:123)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:33)
at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run
(ServletS tubImpl.java:1006)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
pl.java:4 19)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
pl.java:4 63)
at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:28)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.ja
va:27)
at com.bea.wlw.netui.pageflow.PageFlowJspFilter.doFilter(PageFlowJspFilt
er.java:2 61)
at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.ja
va:27)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationActio
n.run(Web AppServletContext.java:6724)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(Authenticate
dSubject. java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:
121)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppSe
rvletCont ext.java:3764)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestIm
pl.java:2 644)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:219)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:178)
>



<u>< i><b>ReportBIRT.jsp</b></i></u>







public void returnFile(String filename, OutputStream fout)
throws FileNotFoundException, IOException
{
InputStream in = null;
try
{
in = new BufferedInputStream(new FileInputStream(filename));
byte[ ] buf = new byte[4 * 1024]; // 4K buffer
int bytesRead;
while ((bytesRead = in.read(buf)) != -1)
{
fout.write(buf, 0, bytesRead);
}
}
finally
{
if (in != null) in.close( );
}
}





response.setContentType("text/html");
response.setHeader("Pragma", "no-cache");
response.setHeader("Cache-Control", "no-cache");
response.setDateHeader("Expires", 0);


HttpSession mysession=request.getSession(true);
OutputStream out_frame = response.getOutputStream( );


/*String reportName = request.getParameter("selectreport");
System.out.println("reportName=="+reportName);
String reportType = request.getParameter("selecttype");
System.out.println("reportType=="+reportType);
*/

String reportName = "C:/Documents and Settings/Administrator/workspace/My First Report/SubReport.rptdesign";
String reportType ="PDF";

InputStream fin = new FileInputStream(reportName);
/*
Vector reportFile = ReportEngineDatabaseLayer.downrpt(reportName);
InputStream in=null;
if (reportFile != null) {
for(int j=0;j<reportFile.size();j++){
Vector vModule = (Vector)reportFile.elementAt(j);
in = (InputStream)vModule.elementAt(1);
}
}
*/

boolean showInfo = false;
HashMap params = new HashMap();
String tfor = new String();
String format ="";
if(reportType.equals("HTML"))
{
format="html";
System.out.println("HTML File");
}

else{
format="pdf";
response.setContentType("application/pdf");

}

Pdf.run( fin, params, format, showInfo);

response.setContentType("application/pdf");

String mmm="C:/diwakar.pdf";
returnFile(mmm,out_frame);

Topic: problem with recurssion Previous Topic   Next Topic Topic: Help me please.. [Matrix]

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use