on 03-26-2007 1:02 PM
Dear all
I had try development the module to validate xml schema follow this
public void SAXValidation(InputStream tmpXML,InputStream tmpXSD,byte b1[]) throws Exception {
try {
SAXParserFactory saxParserFactory = SAXParserFactory.newInstance();
saxParserFactory.setNamespaceAware(true);
saxParserFactory.setValidating(true);
SAXParser saxParser = saxParserFactory.newSAXParser();
saxParser.setProperty("http://java.sun.com/xml/jaxp/properties/schemaLanguage", "http://www.w3.org/2001/XMLSchema");
saxParser.setProperty("http://java.sun.com/xml/jaxp/properties/schemaSource", tmpXSD);
DefaultHandler handler = new DefaultHandler();
saxParser.parse(tmpXML, handler);
}
catch(Exception exc) {
CreateFile("i://xitest/test1/ValidationResult.txt",exc.toString());
}
}
But I got this error
org.xml.sax.SAXNotRecognizedException: Property: http://java.sun.com/xml/jaxp/properties/schemaLanguage
Could you please suggest?
Thanks
Park
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Dear all
Thank you very much for your help. I'll try it. But however if anyone have the example code. Kindly please post to guide me.
Thanks
Park
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Java code for xml schema validation in XI:
http://help.sap.com/saphelp_nw2004s/helpdata/en/c4/e1343e8c7f6329e10000000a114084/frameset.htm
Though it does declares the same properties as you did.
Kinda strange... which version/SP are you on?
Regards,
Henrique.
Hi Park,
Actually the SaxParser of SAP XI is not JAXP 1.2 compliant. Thus you get this error.
Try using an external JAXP 1.2 or above compatible class for this problem.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Park,
you are getting org.xml.sax.SAXNotRecognizedException error because in statement:
<i>saxParser.setProperty("http://java.sun.com/xml/jaxp/properties/schemaLanguage", "http://www.w3.org/2001/XMLSchema");</i>
you are setting the http://java.sun.com/xml/jaxp/properties/schemaLanguage property the value http://www.w3.org/2001/XMLSchema.....but http://java.sun.com/xml/jaxp/properties/schemaLanguage cant be a property name......the property name can be schemaLanguage....
similarly http://java.sun.com/xml/jaxp/properties/schemaSource cant be a property name......schemaSource can be a property name.......
Thanks,
Rajeev Gupta
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Plz see the below link
https://websmp108.sap-ag.de/~sapdownload/011000358700003237612005E/HowToCreateAdapterModules.pdf
Regards
Chilla
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Chilla
Thanks for you help. But I can't get it. I got this page.
-
Error Message - ObjectID not existant
What happened?
ObjectID not found in R/3
What can you do?
Check your ObjectID
Error code: WEBSMP108-20070326140715-0014
Error details: 10021D7E-702/1A00C/3162-63F0CFB9-3CB9265-2992F9
Service Name: SAPIDB
Service Server: PWDF1736
Process-ID: 5012
Thread-ID: 5572
Sorry for any inconvenience.
Your SAP Service Marketplace Team
-
Thanks
Park
User | Count |
---|---|
91 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.