|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Writing a node like xs:element to fileI need to complement some information in a xml file, using the Xml.XmlDocument object. This xml contains several <xs:element ....> nodes (is a saved dataset), and I need to write new nodes exactly in the same way the existant nodes. I tried naming the new node as "xs:element" or type the "element" in the namespaceURI, but it when I see creates a namespace in the text file, in both cases. How can I do that? Cesar Code sample I tried: Dim nod As Xml.XmlNode = xmldocSchema.CreateNode(Xml.XmlNodeType.Element, "xs:element", "") nodOther.AppendChild(nod) Dim nod As Xml.XmlNode = xmldocSchema.CreateNode(Xml.XmlNodeType.Element, "xs", "element") nodOther.AppendChild(nod) Cesar,
Why do you than not create your own dataset by hand and write that with writeXML \\\ Dim ds as new DataSet("Cesar") Dim dt As New DataTable("Persons") ds.tables.add(dt) dt.Columns.Add("Name") dt.Columns.Add("USA", GetType(System.Boolean)) dt.LoadDataRow(New Object() {"Ken Tucker", True}, True) dt.LoadDataRow(New Object() {"Cor Ligthert", False}, True) ds.writeXML("Path") /// I hope this helps, Cor "ronchese" <info(a)carsoftnet.com.br> schreef in bericht news:eSS%23$P%23mGHA.3432@TK2MSFTNGP02.phx.gbl... Hello All.I need to complement some information in a xml file, using the Xml.XmlDocument object. This xml contains several <xs:element ....> nodes (is a saved dataset), and I need to write new nodes exactly in the same way the existant nodes. I tried naming the new node as "xs:element" or type the "element" in the namespaceURI, but it when I see creates a namespace in the text file, in both cases. How can I do that? Cesar Code sample I tried: Dim nod As Xml.XmlNode = xmldocSchema.CreateNode(Xml.XmlNodeType.Element, "xs:element", "") nodOther.AppendChild(nod) Dim nod As Xml.XmlNode = xmldocSchema.CreateNode(Xml.XmlNodeType.Element, "xs", "element") nodOther.AppendChild(nod)
ActiveX.exe and RaiseEvent
need help with a string manipulation. Late Binding Return Value Weirdness String and int Issue MDI Form loading Hindi numbers in Graphics class Visual Basic 6.0, Enterprise Edition ASP.NET: VSNET2003 to VSNET2005 Global.asax.vb in Visual Studio .NET 2005 determine which radiobutton in a groupbox is checked? |
|||||||||||||||||||||||