Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I don't want the <NewDataSet> tag in my XML

Status
Not open for further replies.

inza141

Programmer
Jan 25, 2006
5
NL
Hi All
I have a big problem i have a dataset that I would like
to write to a xml file. I don't have any problem doing
that but the xml starts and ends with this tag:
<NewDataSet>
I don't whant that start tag. The rest of the xml looks
like the one I would like to have.
Does anybody know how to tell the DataSet not to write
the first element <NewDataSet> ??????

I can't find any solutions on the Internet, and yes I
could work with the xml and reformat it with xsl or
xpath. But that is an performance issue so I don't whant
to do that..
 
is this a .net dataset ??
if so then create a new one:

XmlNodeList xmlNew = xmlOld.DocumentElement.SelectNodes(@"NewDataSet")
 
The op should look into the DataSetName property. Or, at instantiating time, assign the DataSetName to it.
[tt] DataSet ds=new DataSet("yourname");[/tt]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top