Subject: Schema and Data in the same file, check possible?
Posted By: lpinho Post Date: 12/4/2003 6:29:54 AM
Hi There,

   I've created a XML file that contains a schema and the data, I would like to know if there's any problem in doing this?
and,

   Is it possible to make a validation in VB(data againt schema), if yes, how (simple example, please)?

Thank You

   Luís Pinho


Example:


 <?xml version="1.0" encoding="UTF-16" standalone="yes" ?> 
 <IfxXmlDoc>
 <xs:schema xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" version="1.0" id="NewDataSet" xmlns:xs="http://www.w3.org/2001/XMLSchema">
 <xs:element name="IfxXmlDoc">
 <xs:complexType>
 <xs:sequence>
  <xs:element minOccurs="0" name="string" nillable="true" type="xs:string" /> 
  <xs:element minOccurs="0" name="int_i32" nillable="true" type="xs:int" /> 
  <xs:element minOccurs="0" name="long_i64" nillable="true" type="xs:long" /> 
  <xs:element minOccurs="0" name="f32" nillable="true" type="xs:Float" /> 
  <xs:element minOccurs="0" name="f64" nillable="true" type="xs:double" /> 
  <xs:element minOccurs="0" name="date" nillable="true" type="xs:dateTime" /> 
  <xs:element minOccurs="0" name="boolean" nillable="true" type="xs:boolean" /> 
  <xs:element minOccurs="0" name="opaque" nillable="true" type="xs:base64Binary" /> 
  </xs:sequence>
  </xs:complexType>
  </xs:element>
  </xs:schema>
  <string>This is a simple example string</string> 
  <int_i32>10000</int_i32> 
  <long_i64>234567345673456</long_i64> 
  <f32>2132131</f32> 
  <f64>2132131</f64> 
  <date>04-12-2003 11:29:13</date> 
  <boolean>True</boolean> 
  </IfxXmlDoc>



Go to topic 7202

Return to index page 993
Return to index page 992
Return to index page 991
Return to index page 990
Return to index page 989
Return to index page 988
Return to index page 987
Return to index page 986
Return to index page 985
Return to index page 984