xml - xsi:schemaLocation element type not bound -


pretty new xml. validator throws error.

full error prefix "xsi" attribute "xsi:schemalocation" associated element type "mpreader" not bound.

heres clip of xml

<?xml version="1.0" encoding="utf-8" standalone="no"?> <mpreader xmlns="c:\users\dallan\desktop\mpreader\" xmlns:xs="http://www.w3.org/20one/xmlschema-instance"   xsi:schemalocation="c:\users\dallan\desktop\mpreader\mpreaderschemafinal.xsd">               <firmware>"3.4.16"</firmware>               <hardware>"2.3.53"</hardware>             <sn>"234-1three5"</sn> 

and clip of xsd

    <?xml version="1.0" encoding="utf-8"?> <xs:schema xmlns:xs="http://www.w3.org/2001/xmlschema" xmlns="c:users/dallan/desktop/mpreader/" elementformdefault="qualified" targetnamespace="c:\users\dallan\desktop\mpreader\">  <xs:element name="mpreader"> <xs:complextype> <xs:sequence maxoccurs="unbounded">     <xs:element name="firmware" type="xs:string"/>     <xs:element name="hardware" type="xs:string"/>     <xs:element name="sn" type="xs:string"/>     <xs:element name="devices">         </xs:sequence>         </xs:complextype>         </xs:element> </xs:sequence> </xs:complextype> </xs:element> </xs:schema> 

i had similar issue had custom xml needed parse jaxb.

for parse correctly needed add xmlns:xsd="http://www.w3.org/2001/xmlschema" , xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" namespaces.

i changed this:

<notifications xmlns="http://some/namespace"> 

to this:

<notifications xmlns="http://some/namespace" xmlns:xsd="http://www.w3.org/2001/xmlschema" xmlns:xsi="http://www.w3.org/2001/xmlschema-instance"> 

i think in case may need add both of them missing.


Comments

Popular posts from this blog

c - Bitwise operation with (signed) enum value -

xslt - Unnest parent nodes by child node -

YouTubePlayerFragment cannot be cast to android.support.v4.app.Fragment -