View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Peter Huang [MSFT] Peter Huang [MSFT] is offline
external usenet poster
 
Posts: 225
Default Smart Documents - XSD and Namespace

Hi

Based on my research, the two schema should be compatible.
[Schema:SimpleSample]
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="SimpleSample"
targetNamespace="SimpleSample"
elementFormDefault="qualified"

<xsd:complexType name="exampleType"
<xsd:all
<xsd:element name="textbox" type="xsd:string"/
<xsd:element name="commandbutton" type="xsd:string"/
<xsd:element name="help" type="xsd:string"/
<xsd:element name="radiobutton" type="xsd:string"/
<xsd:element name="checkbox" type="xsd:string"/
<xsd:element name="listbox" type="xsd:string"/
<xsd:element name="image" type="xsd:string"/
<xsd:element name="documentfragment" type="xsd:string"/
<xsd:element name="activex" type="xsd:string"/
<xsd:element name="hyperlink" type="xsd:string"/
</xsd:all
</xsd:complexType

<xsd:element name="example" type="exampleType"/

</xsd:schema

[Export xml]
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?
- <ns1:example xmlns:ns1="SimpleSample"
<ns1:textbox1</ns1:textbox
<ns1:commandbutton /
<ns1:help /
<ns1:radiobutton /
<ns1:checkbox /
<ns1:listbox /
<ns1:image /
<ns1:documentfragment /
<ns1:activex /
<ns1:hyperlink /
</ns1:example

changed to
<?xml version="1.0" encoding="UTF-8" standalone="yes"?
<ns1:example xmlns:ns1="SimpleSample"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="SimpleSample C:\test\SimpleSample.xsd"
<ns1:textbox1</ns1:textbox
<ns1:commandbutton/
<ns1:help/
<ns1:radiobutton/
<ns1:checkbox/
<ns1:listbox/
<ns1:image/
<ns1:documentfragment/
<ns1:activex/
<ns1:hyperlink/
</ns1:example

We will find that we can use the SimpleSample.xsd to validate the exported
xml so they should be compatible. That is to say the webservice will
recognize the xml file.

If you have any concern, please feel free to post here.

Best regards,

Peter Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.