delphi - How to create xml based on this xsd? -


i have xsd , trying create xml file using nativexml (delphi).

<xs:element maxoccurs="unbounded" name="program">  <xs:complextype>   <xs:attribute name="provider" use="required">    <xs:simpletype>     <xs:restriction base="xs:string">      <xs:minlength value="2" />      <xs:maxlength value="6" />     </xs:restriction>    </xs:simpletype>   </xs:attribute>   <xs:more attributes\>  </xs:complextype> </xs:element> 

i created following code:

node := adoc.root.nodenew('student'); node.writeattributeinteger('provider',var_with_data); 

how can create restrictions?


Comments