Answer the question
In order to leave comments, you need to log in
How to get data from DB and cast it to XML in C#?
There is ready data in the database in the program. How to create XML and write them there.
Pulling data from the database is not difficult using the SqlDataAdapter, but then it is not clear how to work with this object and
put the data into XML
Answer the question
In order to leave comments, you need to log in
what for? (this is not a joke)
1 - divide the task into 2:
- get the data
- put it somewhere (in this case, serialization in XML )
.. this will reduce the noise in the head .. in other words - it will become clearer))
2 - but if suddenly SQL == MS SQL, then there is a ready-made feature (if anything - in an article on MSDN, you can select the whine version ..
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question