Create an XML tree in a namespace : XML Tree « XML « VB.Net






Create an XML tree in a namespace

 
Imports System
Imports System.Xml
Imports System.Xml.XPath

Public Class MainClass

    Public Shared Sub Main()
        
        Dim root As XElement = _ 
            <Root xmlns='http://www.domain.com'>
                <Child>child content</Child>
            </Root>
        Console.WriteLine(root)
        
    End Sub
End Class

   
  








Related examples in the same category

1.Use Tree to Display XML document
2.Create an XML tree with nested namespaces
3.Create an XML tree with nested namespaces
4.XStreamingElement represents elements in an XML tree that supports deferred streaming output.