[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] XML Schema Validation Problem
Title: XML Schema Validation Problem Hi everybody, Firstly, I'm new to the list so a quick intro, I program in VB6 SP5 MSXML4 at work OS is Windows 2K Professional. My experience is fairly short with XML (approx 6-8 months), currently I am building XML-Schemas for data exchange between two progams. I have used XSLT in the past but it is not required for this project. I am having a problem with namespaces at the moment and wondered if anyone could help. Obviously if this is the wrong forum for this question please let me know ;-) I have a Schema that has 2 namespaces. This is referenced by an XML document. I can successfully parse the XML against the schema, however I cannot then assign any data to an Object using the SelectSingleNode method of a FreeThreadedDOMDocument40. According to the object browser this should return an IXMLDOMNode, the result I get is the object is still nothing. (Sample XML1) ***************
</Environment> *********************************
<?xml version="1.0" encoding="UTF-8"?>
If I remove the Namespaces and just use a basic structure (Sample XML2), the xml still parses and I get a return value from SelectSingleNode. The only problem being that the schema is not then enforced and I can invent any tags I like in the xml without a parse error (Sample XML3). ****************
<?xml version="1.0" encoding="UTF-8"?>
</Environment> ****************
Incidentally I have tried using the Microsoft example from the MSDN and this has the same problem. Thanks in advance Jason Jason Brown
Tel: (01223) 728 670
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|