Link to home
Start Free TrialLog in
Avatar of studysolution0920
studysolution0920

asked on

java xml schema validation

Hello Expert:
                   I want to ask you a question. how I can  use

javax.xml.validation.SchemaFactory.newInstance("http://www.w3.org/XML/XMLSchema/v1.1") to validation a xml file with corresponding xml Schema file

Because I get the error information:

java.lang.NoSuchFieldError: W3C_XML_SCHEMA11_NS_URI
org.apache.xerces.jaxp.validation.XMLSchema11Factory.<init>(Unknown Source)
ASKER CERTIFIED SOLUTION
Avatar of Mick Barry
Mick Barry
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of studysolution0920
studysolution0920

ASKER

Hello Expert:
                  I have tried to use the method you have give to solve the problem. But the errors are still thrown away again.  I have uploaded the method validation. Can you check it? Thanks! User generated image User generated image
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hello Expert:
                  I use xercesImpl-2_10_0 and xercesImpl-2.10.0-xml-schema-1.1-beta. Is it correct?
thanks!