-
Generate Xml from DataSet
Hi,
I am populating a datagrid with a dataset, after making required changes user will press
Save button, which will save updated records in dataset.
after that i am generating an xml file from dataset like this
<NewDataSet>
<Person>
<PERSONFNAME>ABC</PERSONFNAME>
<PERSONLNAME>DEF</PERSONLNAME>
<ENTRYDATE>2006-01-12</ENTRYDATE>
<AGE>15</AGE>
</Person>
<Person>
<PERSONFNAME>Mahesh</PERSONFNAME>
<PERSONLNAME>Maheshwari</PERSONLNAME>
<ENTRYDATE>2006-01-12</ENTRYDATE>
<AGE>21</AGE>
</Person>
</NewDataSet>
i want to add an attribute to all element which are modified by user.
instead of this xml file i want to get an xml file like this
<NewDataSet>
<Person>
<PERSONFNAME originalValue="XYZ">ABC</PERSONFNAME> (Changed by user in DataGrid)
<PERSONLNAME originalValue="BBCA">DEF</PERSONLNAME> (Changed by user in DataGrid)
<ENTRYDATE>2006-01-12</ENTRYDATE>
<AGE originalValue="21">15</AGE> (Changed by user in DataGrid)
</Person>
<Person>
<PERSONFNAME>Mahesh</PERSONFNAME>
<PERSONLNAME>Maheshwari</PERSONLNAME>
<ENTRYDATE>2006-01-12</ENTRYDATE>
<AGE>21</AGE>
</Person>
</NewDataSet>
How can i do that, Please help me
Regards
Mahesh
-
Investigate the DataSet.WriteXML method.
Neal
VB.NET Forums Admin
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
Bookmarks