XML with inline schema supported in Excel? -


i need generate simple xml file (a list of users) xsd xml can imported in excel (2010+). fields presented xml dynamic, it's user fields wants/needs. list can long , have 40 fields user can select from.

excel builds table columns based upon xml schema. if first row has missing fields, these added table in wrong order. schema required! since xml based on request, xml schema must inline.

based on every article find inline schema's i've created following.. crash'n burn every validator. excel won't accept either.

<?xml version="1.0" encoding="utf-8"?>  <users xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xsi:nonamespaceschemalocation="#local">   <xs:schema id="local" xmlns:xs="http://www.w3.org/2001/xmlschema">     <xs:element name="users">       <xs:complextype>         <xs:sequence>           <xs:any processcontents="skip" namespace="http://www.w3.org/2001/xmlschema" minoccurs="0" maxoccurs="1"/>           <xs:element ref="user" minoccurs='1' maxoccurs='unbounded'/>         </xs:sequence>       </xs:complextype>     </xs:element>      <xs:element name="user">       <xs:complextype>         <xs:sequence>           <xs:element ref="firstname" minoccurs='0' maxoccurs='1'/>           <xs:element ref="lastname" minoccurs='0' maxoccurs='1'/>           <xs:element ref="phone" minoccurs='0' maxoccurs='1'/>         </xs:sequence>       </xs:complextype>     </xs:element>      <xs:element name="firstname" type="xs:string"/>     <xs:element name="lastname" type="xs:string"/>     <xs:element name="phone" type="xs:string"/>    </xs:schema>    <user>     <lastname>doe</lastname>     <phone>123456789</phone>   </user>   <user>     <firstname>john</firstname>     <lastname>something</lastname>   </user>   <user>     <firstname>jesus</firstname>     <lastname>christ</lastname>     <phone>987654321</phone>   </user> </users> 

what heck doing wrong? seems simple...


Comments

Popular posts from this blog

java - How to specify maven bin in eclipse maven plugin? -

Error while updating a record in APEX screen -

c++ - In an add-in in Excel, written in C(++), how does one get the name of the function which called into the addin? -