File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Java Advanced Imaging

 
Stephanie Grasson
Ranch Hand
Posts: 347
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
I think this is a simple classpath-type problem, but I am stumped. I am using JDK 1.2.2 on a WindowsNT 4.0 workstation. Please advise:
I downloaded the Java Advanced Imaging (JAI) extension and installed it in my JDK1.2.2 folder (default installation). When I try to run any of the sample programs, I get errors such as:
"Exception in thread "main" java.lang.NoClassDefFoundError: javax/media/jai/PlanarImage at JAIDemo.main".
I can see the class in question
(javax/media/jai/PlanarImage.class)
in a jar file (jai_core.jar) in the following path:
h:\java\jdk1.2.2\jre\lib\ext.
As near as I can tell from the documentation, this is the appropriate location.
Can anyone please tell me what I'm doing wrong?
Thanks in advance for your help.
Stephanie
 
Jim Yingst
Wanderer
Sheriff
Posts: 18671
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For a jar file, you need to include the full path of the jar file itself (not merely the directory it's in) as part of your CLASSPATH. So in this case "h:\java\jdk1.2.2\jre\lib\ext\jai_core.jar" needs to be in your CLASSPATH. It would be nice if the installer took care of this for you, but often they don't.
 
Stephanie Grasson
Ranch Hand
Posts: 347
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jim,
Thanks for your response! It's working now.
Stephanie
 
sourabh malhotra
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi!.. i hav eread your problem .. i m facing teh same problem trying to run jai tutor... have also given teh classpath but still cant make it... can some one say y?
 
Aj Manch
Ranch Hand
Posts: 50
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am not sure what the solution is. But, in this case, putting the jar file in the Classpath isn't one either. The jars in the extensions directory don't have to specified in the classpath. The JVM extensions classloader looks for them automatically.
[ June 04, 2002: Message edited by: Aj Manch ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic