aspose file tools*
The moose likes IDEs, Version Control and other tools and the fly likes scriptlet class not found while running jasper from eclipse Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Bookmark "scriptlet class not found while running jasper from eclipse" Watch "scriptlet class not found while running jasper from eclipse" New topic
Author

scriptlet class not found while running jasper from eclipse

ahmad khawaja
Greenhorn

Joined: Sep 02, 2004
Posts: 4
hey guys,
i have a scriptlet class called "com.tdsecurities.overage.report.DailyReportScriptlet"

when i try to use it in my report on a field i get the following exception

java.lang.ClassNotFoundException: com.tdsecurities.overage.report.DailyReportScriptlet
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at dori.jasper.engine.util.JRClassLoader.loadClassForName(JRClassLoader.java:115)
at dori.jasper.engine.fill.JRBaseFiller.loadScriptlet(JRBaseFiller.java:573)
at dori.jasper.engine.fill.JRBaseFiller.<init>(JRBaseFiller.java:314)
at dori.jasper.engine.fill.JRVerticalFiller.<init>..........


ALL my classes compile but some thing happens at run time due to which it cant find it . I am using sunshine plugin for eclipse 3.0 .I have tried combinations of setting class paths like putting.jasper file in bin directory , setting system class path to eclipse bin,copying .jasper and scriptlet class in same directory etc ...but doesnt seem to help. I know its some thing to do with eclipse setting of run time class path but cant figure out any help will be appreicated.
thanks
ahmad
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60046
    
  65

Since this is most likely an Eclipse setup issue, I'll move this along to the IDE's forum where the Eclipse-savvy hang out.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29220
    
135

Ahmad,
Is the jar in your java jar dependencies list for the web project? This is used at runtime, while the build path is used at compile time.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
ahmad khawaja
Greenhorn

Joined: Sep 02, 2004
Posts: 4
hey Jeane ,
Thanks for te timely response.

Which jar are you referring to ? The jar that contains jasper files or jar that has scriptless class. I am not running a web application.aFor simplicity I even dont make a jar file . i compile classes and then just try to run the jasper (without running web server). I am not sure which class path eclipse uses at run time? Is it different than build path? ...Let me give u brief summary
1..I compile source code from project\src directory to project\bin
2..I have xml file which gets converted to jasper
3..I refer to the classes which i compiled in step 1 in jasper and get exception
I have tried putting jasper and compiled classe in same directory.
I have also tried setting system class path to project\bin.

Moreover what is run time class path of eclipse and how can i set it
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29220
    
135

Ahmad,
Sorry, I saw DailyReportScriptlet and assumed it had something to do with web project.

I was referring to the java containing DailyReportScriptlet. My comment only applies to web projects. Are you using a simple java project?
ahmad khawaja
Greenhorn

Joined: Sep 02, 2004
Posts: 4
Yes. I am trying to view the report through the standalone application. (In fact once i get the jasper file generated by sunshinereports plug in , and when i try to convert it into html i get this exception).
Ilja Preuss
author
Sheriff

Joined: Jul 11, 2001
Posts: 14112
Originally posted by ahmad khawaja:
Yes. I am trying to view the report through the standalone application. (In fact once i get the jasper file generated by sunshinereports plug in , and when i try to convert it into html i get this exception).


Does the exception occur when you compile the report xml, or when you execute the already compiled report? If the former, how do you compile?


The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: scriptlet class not found while running jasper from eclipse
 
Similar Threads
scriptlet class not found while running jasper from eclipse
Problem with an applet
JFree Chart in iReport...help me!
My applet is not being seen in its jar anymore. Please help!
Loading java applet from a cab file failed