Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / First Aid / July 2007

Tip: Looking for answers? Try searching our database.

I need help, I have problom using iReport

Thread view: 
sahm - 15 Jul 2007 17:32 GMT
HI every no

I have problom with this code
this code for create report in java using iReport

///////////////////////////////////////////////

String reportSource = "./src/test_db/report/templates/
HelloReportWorld.jrxml";
String reportDest = "./src/test_db/report/results/
HelloReportWorld.html";

Map<String, Object> params = new HashMap<String, Object>();
JOptionPane.showMessageDialog(this, "NO. 3");

try
{
JasperReport jasperReport =
JasperCompileManager.compileReport(reportSource);

JasperPrint jasperPrint = JasperFillManager.fillReport(jasperReport,
params, new JREmptyDataSource());

JasperExportManager.exportReportToHtmlFile(jasperPrint, reportDest);

JasperViewer.viewReport(jasperPrint);
}

catch (JRException ex)
{
JOptionPane.showMessageDialog(this, ex.toString());
}

////////////////////////////////////////

when I run the code this error is showing
<<< net.sf.jasperreports.engine.JRException: Error Compiling java
Source files: E:\Salim\Project\test_DB
\HelloReportWorld_1184573407625.java >>>

and I do not have any file with this name
(HelloReportWorld_1184573407625.java)

Best Salim
Andrew Thompson - 15 Jul 2007 17:59 GMT
> HI every no

Please refrain from multi-posting, in future.
<http://www.physci.org/codes/javafaq.html#xpost>

> I have problom with this code
> this code for create report in java using iReport

One problem in helping you with this code
is that it is not complete, or compilable
(as in, we cannot compile it to see the
same errors here).

Please consider posting SSCCE's in future.
<http://www.physci.org/codes/sscce.html>
...
(snip)
> when I run the code ..

Run time and compile time errors (and
exceptions) are very different things,
and it looks as though this is a 'compile
error', rather than a 'run error'.

>..this error is showing
> <<< net.sf.jasperreports.engine.JRException: Error Compiling java
[quoted text clipped - 3 lines]
> and I do not have any file with this name
> (HelloReportWorld_1184573407625.java)

Is this a servlet, or JSP?

(N.B. X-post to c.l.j.p./h., w/ f-u to c.l.j.h. only)
sahm - 15 Jul 2007 18:09 GMT
> > HI every no
>
[quoted text clipped - 32 lines]
>
> (N.B. X-post to c.l.j.p./h., w/ f-u to c.l.j.h. only)

NO it is J2SE
sahm - 15 Jul 2007 18:11 GMT
> > HI every no
>
[quoted text clipped - 32 lines]
>
> (N.B. X-post to c.l.j.p./h., w/ f-u to c.l.j.h. only)

No It is J2SE
Roedy Green - 15 Jul 2007 19:25 GMT
On Sun, 15 Jul 2007 09:59:53 -0700, Andrew Thompson
<andrewthommo@gmail.com> wrote, quoted or indirectly quoted someone
who said :

>One problem in helping you with this code
>is that it is not complete, or compilable
>(as in, we cannot compile it to see the
>same errors here).

that's not going to help in this case.  Not many people will have
Jasper ireport.
Signature

Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com

Roedy Green - 15 Jul 2007 19:24 GMT
>when I run the code this error is showing
><<< net.sf.jasperreports.engine.JRException: Error Compiling java
[quoted text clipped - 3 lines]
>and I do not have any file with this name
>(HelloReportWorld_1184573407625.java)

Presumably it is some generated source code.  do a search for
HelloR*.java on all your disks.
Signature

Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.