One of the approaches to instantiate an XML file (I am unfortunately made to
use) is to read XSD file into a DataSet.
This will create a data set of the specified structure.
After that you may use WriteXML(fileName) method to generate and XML file.
There are two potential problems.
1. Not every XSD may be read into data set. Some legal constructions cause
errors while parsing.
2. You'll need to add some information to the dataset before you write XML.
Otherwise you will get an XML file consisting of <YourRootElement /> only.
(Do not forget to set msdata:IsDataSet="true" attribute in the root element
of your dataset, where msdata is
xmlns:msdata="urn:schemas-microsoft-com:XML-msdata".)
Good Luck.
"Gionni" <eh*******@katamail.com> wrote in message
news:uQ****************@tk2msftngp13.phx.gbl...
Hello everyone,
I'm trying to generate a xml instance with some default values from a
xsd schema with vb.net. I think .net does not provide any classes to do
this, does it? Alternatively are there any third classes namespaces that make this
operation or I have to do generate the xml instance on my own?
Thanks to all, Gionni
************************************************** ********************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP &
ASP.NET resources...