how to change rootelement

EDN Admin

Well-known member
Joined
Aug 7, 2010
Messages
12,794
Location
In the Machine
each xdocument created with a dataset has a root element <NewDataSet>
i want to change this.

but the

<div style="color:Black;background-color:White; <pre>
<span style="color:Blue; Dim xmlFile <span style="color:Blue; As XDocument
<span style="color:Blue; Dim el <span style="color:Blue; As XElement

xmlFile = XDocument.Load(id_xmlfilestring)

el = xmlFile.<NewDataSet>

el.ReplaceWith(<InstalledDevices><%= el.Nodes %></InstalledDevices>)
[/code]
Unable to cast object of type <GetElements>d__11 to type System.Xml.Linq.XElement. fault at
el = xmlFile.<NewDataSet>
what is wrong. <hr class="sig nattelip

View the full article
 
Back
Top