• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

NoClassDefFoundError

 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm trying to call an RPG program from java using a PCML class. All classes are compiled ok but at runtime I get ...
java.lang.NoClassDefFoundError: org/apache/xerces/framework/XMLParser
Help
 
Bartender
Posts: 1844
Eclipse IDE Ruby Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What does your CLASSPATH look like? Have you included the Xerces jar file in you Classpath (I think that it's called XercesImpl.jar).
 
DANIELA PINES
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It's in the xerces.jar and I have it in the classpath. I even downloaded the newest version.
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello
I too had the same problem and i found out that the problem comes from different versions of jt400.jar,data400.jar and xml4j.jar.
Strangely on the AS400 there are multiple copies of these files available
I solved the problem by creating a standalone program and testing with different versions of the files till i got it rt adn then adding these files to the web application classpath.
public class PCMLTest {

public static void main(String[] args) throws PcmlException {
AS400 as400 = new AS400("ip","user","password");
System.out.println("as400 obj created");
String pcmlFileName="TestPcml.pcml";
ProgramCallDocument pcd=new ProgramCallDocument(as400 , pcmlFileName);
System.out.println("Initialisation of pcml is thru");
}
}

The original problem i had was that it said xerces/XMLParser file was missing(NoClassDefFound) even though the file was present in the classpath and accessible.
Hope it helps
[ August 25, 2004: Message edited by: jomy davis ]
 
reply
    Bookmark Topic Watch Topic
  • New Topic