H
hooomee
I'm having tons of trouble getting my schema namespace to work. When i
point the validator at the following two examples, it gives the error:
Warning at (2,2): Could not find schema information for the element
'pleaseWork:aWidget'.
I'm trying to validate it using:
http://apps.gotdotnet.com/xmltools/xsdvalidator/default.aspx
What am I missing/not understanding? I'm familiar with namespaces
from C++, but cant seem to get this right.
instance.xml:
<?xml version="1.0" encoding="utf-8" ?>
<aWidget xmlns="pleaseWork">
<Model>3x4x1.5</Model>
</aWidget>
namespace.xsd:
<?xml version="1.0" encoding="utf-8" ?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="pleaseWork" xmlns="pleaseWork" >
<xs:element name="aWidget" type="Widget" />
<xs:complexType name="Widget">
<xs:all>
<xs:element name="Model" type="xs:string" />
</xs:all>
</xs:complexType>
</xs:schema>
point the validator at the following two examples, it gives the error:
Warning at (2,2): Could not find schema information for the element
'pleaseWork:aWidget'.
I'm trying to validate it using:
http://apps.gotdotnet.com/xmltools/xsdvalidator/default.aspx
What am I missing/not understanding? I'm familiar with namespaces
from C++, but cant seem to get this right.
instance.xml:
<?xml version="1.0" encoding="utf-8" ?>
<aWidget xmlns="pleaseWork">
<Model>3x4x1.5</Model>
</aWidget>
namespace.xsd:
<?xml version="1.0" encoding="utf-8" ?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
targetNamespace="pleaseWork" xmlns="pleaseWork" >
<xs:element name="aWidget" type="Widget" />
<xs:complexType name="Widget">
<xs:all>
<xs:element name="Model" type="xs:string" />
</xs:all>
</xs:complexType>
</xs:schema>