User1508394307 posted
Read Generating XML Documents from XML Schemas
In general, to make a document based on schema you need
XmlTextWriter textWriter = new XmlTextWriter("po.xml", null);
textWriter.Formatting = Formatting.Indented;
XmlQualifiedName qname = new XmlQualifiedName("PurchaseOrder", "http://tempuri.org");
XmlSampleGenerator generator = new XmlSampleGenerator("po.xsd", qname);
genr.WriteXml(textWriter);