-4

I want to create XML file with data(data is from database) using existing XSD file. Please guide me how to do this in C#

4

1 回答 1

1

Here's one way:

  1. Use xsd.exe to create a set of class definitions from your schema.
  2. Populate instances of those classes from the database.
  3. Use XmlSerializer to serialize those instances to XML.
于 2013-03-11T20:30:18.323 回答