• 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Paul Clapham
  • Jeanne Boyarsky
  • Knute Snortum
Sheriffs:
  • Liutauras Vilda
  • Tim Cooke
  • Junilu Lacar
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Joe Ess
  • salvin francis
  • fred rosenberger

Trouble setting up and running Xerces-2_6_2

 
Ranch Hand
Posts: 158
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am having trouble setting up and running Xerces-2_6_2 on my Windows XP machine. I have followed the installation instruction on apache.org site, worked through installation tutorials on the web, searched this forum & other websites for solutions but am still stuck.

I would truly appreciate any help. Thanks.

Here at the current settings on my system

OS: Windows XP
Java installation:
Sun�s j2sdk1.4.2_07
PATH=c:\Windows\system32;C:\Windows\System32\Wbem;C:\Program Files\ATI Technologies\ATI Control Panel;c:\j2sdk1.4.2_07\bin
(Path set as a System Variable)
JAVA_HOME= c:\j2sdk1.4.2_07
(JAVA_HOME set as User variable)

I am able to compile and run Java programs with this setup.

Installing Xerces-2_6_2
Download Xerces-J-bin 2_6_2.zip
Unpacked the zip files into: c:\xerces-2_6_2

Running Xerces
Launch the Command Prompt and change to the Xerces-2_6_2 directory
Set the CLASSPATH:
set CLASSPATH=c:\xerces-2_6_2\xercesImpl.jar; c:\xerces-2_6_2\xmlParserAPIs.jar; c:\xerces-2_6_2\xml-apis.jar; c:\xerces-2_6_2\xercesSamples.jar;.;%classpath%

Copy an XML File named "intro.xml" and place inside xerces-2_6_2 folder:
<?xml version = "1.0"?>
<myMessage>
<message>First XML Parser Program</message>
</myMessage>
Step 06 - Run the sample sax program named "Counter":
c:\>xerces-2_2_6\java sax.Counter intro.xml
I get these results:
Exception in thread �main� java.lang.NoClassDefFoundError sax/Counter

Not sure what to do from here??
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In the section Running Xerces, you defined the classpath as follows:

set CLASSPATH=c:\xerces-2_6_2\xercesImpl.jar; c:\xerces-2_6_2\xmlParserAPIs.jar; c:\xerces-2_6_2\xml-apis.jar; c:\xerces-2_6_2\xercesSamples.jar;.;%classpath%



(I am not sure if this beloved forum code is inserting spaces on my or your behalf, but, in your message it sure looked like you had a space in your classpath, before the xmlParserAPIs.jar entry.
 
Where does a nanny get ground to air missles? Protect this tiny ad:
Sauce Labs - World's Largest Continuous Testing Cloud for Websites and Mobile Apps
https://coderanch.com/t/722574/Sauce-Labs-World-Largest-Continuous
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!