strong textHello guys! Is there any way to convert an XSD file to an HTML file...what i am trying to achieve here is parse an XSD file and based on that give the user a form where in he can fill in the details...and finally i want to create an XML file by binding that data...For example Consider the following XSD..
<xs:element name="Collection">
<xs:complexType>
<xs:sequence>
<xs:element name ="books">
<xs:complexType>
<xs:sequence>
<xs:element name="book" type="bookType" minOccurs="1" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:complexType name="bookType">
<xs:sequence>
<xs:element name="name" type="xs:string"/>
<xs:element name="ISBN" type="xs:long"/>
<xs:element name="price" type="xs:string"/>
</xs:sequence>
</xs:complexType>
This should give me an HTML form like this
Collection:
Books
Book1:---TextBox---
Name:---TextBox---
ISBN:---TextBox---
Price:---TextBox---
Book2
Name:---TextBox---
ISBN:---TextBox---
Price:---TextBox---
开发者_如何学编程
If there is a choice then it should give the user a redio group etc... any help will be greatly appreciated...
XSL Transformations are often used to translate XML into something else: http://en.wikipedia.org/wiki/XSLT
This site is doing something similar:
http://www.datamech.com/XMLForm/formGenerator4.html
精彩评论