home *** CD-ROM | disk | FTP | other *** search
- <html>
-
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
- <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
- <meta name="ProgId" content="FrontPage.Editor.Document">
- <title>This is a tutorial that will walk you through the application in creating
- a Valid XML given an XSD from dynamic GUI</title>
- </head>
-
- <body><script language="javascript">
- if (window.name != "content")
- document.write("<center><a href='index.html?page=PO_Tutorial.htm'>show framing</a></center>")
- </script>
-
- <p>This is a tutorial that will walk you through the application in creating a <b>Valid
- XML</b> given an XSD from dynamic GUI</p>
- <p><font color="#800000"><b>Sample XSD </b></font>(purchase order) </p>
- <blockquote>
- <p><font size="2"><?xml version="1.0"?><br>
- <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"> </font></p>
- <p><font size="2"> <!--Stock Keeping Unit, a code for identifying products--><br>
- <xs:annotation><br>
- <xs:documentation xml:lang="en">Purchase order schema for Example.com.Copyright 2000 Example.com. All rights
- reserved.</xs:documentation><br>
- </xs:annotation><br>
- <xs:complexType name="PurchaseOrderType"><br>
- <xs:sequence><br>
- <xs:element name="shipTo" type="USAddress"></xs:element><br>
- <xs:element name="billTo" type="USAddress"></xs:element><br>
- <xs:element ref="comment" minOccurs="0"></xs:element><br>
- <xs:element name="items" type="Items"></xs:element><br>
- </xs:sequence><br>
- <xs:attribute name="orderDate" type="xs:date"></xs:attribute><br>
- <xs:attribute name="select" type="xs:boolean"></xs:attribute><br>
- </xs:complexType><br>
- <xs:element name="purchaseOrder" type="PurchaseOrderType"></xs:element><br>
- <xs:element name="comment" type="xs:string"></xs:element><br>
- <xs:complexType name="USAddress"><br>
- <xs:sequence><br>
- <xs:element name="name" type="xs:string"></xs:element><br>
- <xs:element name="street" type="xs:string"></xs:element><br>
- <xs:element name="city" type="xs:string"></xs:element><br>
- <xs:element name="state" type="xs:string"></xs:element><br>
- <xs:element name="zip" type="xs:decimal"></xs:element><br>
- </xs:sequence><br>
- <xs:attribute name="country" type="xs:NMTOKEN" fixed="US"></xs:attribute><br>
- </xs:complexType><br>
- <xs:complexType name="Items"><br>
- <xs:sequence><br>
- <xs:element name="item" minOccurs="0" maxOccurs="unbounded"><br>
-
- <xs:complexType><br>
-
- <xs:sequence><br>
-
- <xs:element name="productName" type="xs:string"></xs:element><br>
-
- <xs:element name="quantity"><br>
-
- <xs:simpleType><br>
-
- <xs:restriction base="xs:positiveInteger"><br>
-
- <xs:maxExclusive value="100"></xs:maxExclusive><br>
-
- </xs:restriction><br>
-
- </xs:simpleType><br>
-
- </xs:element><br>
-
- <xs:element name="USPrice" type="xs:decimal"></xs:element><br>
-
- <xs:element ref="comment" minOccurs="0"></xs:element><br>
-
- <xs:element name="shipDate" type="xs:date" minOccurs="0"></xs:element><br>
-
- </xs:sequence><br>
-
- <xs:attribute name="partNum" type="SKU" use="required"></xs:attribute><br>
-
- </xs:complexType><br>
- </xs:element><br>
- </xs:sequence><br>
- </xs:complexType><br>
- <xs:simpleType name="SKU"><br>
- <xs:restriction base="xs:string"><br>
-
- <xs:pattern value="\d{3}-[A-Z]{2}"></xs:pattern><br>
- </xs:restriction><br>
- </xs:simpleType><br>
- </xs:schema></font></p>
- </blockquote>
- <p><font color="#800000"><b>Steps</b></font>:</p>
- <p>1. From <b>File->New Project</b> select <b>Samples</b>, click Next and select
- <b>PurchaseOrder</b>.</p>
- <p><img border="0" src="jpeg/newproject.gif" width="659" height="445"></p>
- <p>2. Click <b>Create</b>. Dynamic GUI with empty XML document opens as shown below.
- The default values show in blue color. complexTypes are shown in red which
- are always group boxes. The Notepad symbol is useful for editing multiline
- input. When the focus is in a Textbox, clicking this icon will open an
- edit window. Reference elements are shown in green color. These color
- settings can be customized by user.</p>
- <p><img border="0" src="jpeg/guistart.gif" width="638" height="420"></p>
- <p>3. Fill up the data as shown below for the first tab (shipTo)</p>
- <p><img border="0" src="jpeg/shipto.gif" width="633" height="418"></p>
- <p>4. Move to second tab (billTo) and fill data as shown below</p>
- <p><img border="0" src="jpeg/billto.gif" width="631" height="417"></p>
- <p>5. Move to items tab and add first item by entering the data below.</p>
- <p><img border="0" src="jpeg/items1.gif" width="628" height="418"></p>
- <p>6. Create one more item by clicking <b>New</b></p>
- <p><img border="0" src="jpeg/items2.gif" width="636" height="419"></p>
- <p>7. Change the file to po.xml by selecting <b>Rename </b>button</p>
- <p><img border="0" src="jpeg/rename.gif" width="636" height="416"></p>
- <p>8. <b>Save</b> the file </p>
- <p><img border="0" src="jpeg/save.gif" width="644" height="419"></p>
- <p>9. Close the application by pressing <b>Close. </b>Select <b>Files</b>
- icon on the left extreme and this will show the Data files folder. Right
- click on this view and select <b>Refresh. </b><i>po.xml </i>is shown in
- the list.</p>
- <p><img border="0" src="jpeg/filesview.gif" width="279" height="421"></p>
- <p>10. Double Clicking the <i>po.xml</i> opens the XML in GUI as shown below.</p>
- <p><img border="0" src="jpeg/finalopen.gif" width="1023" height="730"></p>
-
- </body>
-
- </html>
-