0

I have a set of xsd files and xml data files. I need to import data from xml files to database. I have .NET 4.0 and Visual Studio 2010.

Which tools can I use? Ideally it should be something, what helps me to read data as entities composed from xml structure.

Fanda
  • 3,760
  • 5
  • 37
  • 56
  • http://stackoverflow.com/questions/2101112/best-practice-using-c-sharp-xsd-typed-datasets-in-enterprise-applications – Frank59 Nov 02 '12 at 14:28

2 Answers2

3

I'd look into using xsd.exe to generate c# classes that adhere to the format specified in the xsd. From there you can use the XmlSerialization objects in .Net to hydrate some objects of the classes generated from xsd.exe. You can then parse your objects however you'd like to in your c# code from there.

Here's a link that may help: http://blogs.msdn.com/b/yojoshi/archive/2011/05/14/xml-serialization-and-deserialization-entity-classes-with-xsd-exe.aspx

Frito
  • 1,423
  • 1
  • 15
  • 27
0

With latest VS version, don't need to use xsd.exe anymore.

Look at topic : XML 2 CS use Method 2 in comments

Community
  • 1
  • 1