0
Answer

Web Browser control with it and display as a Xml

Ask a question
Mahesh Mohan

Mahesh Mohan

10y
854
1
I have a xml. I want to set the value of the Web Browser control with it and display as a Xml.
 
how do I tell it to display as a XML ?


   System.Xml.XmlTextReader oXmlTextReader = new
            System.Xml.XmlTextReader(@"D:\Demo\data.xml");
            System.Text.StringBuilder oStringBuilder = new System.Text.StringBuilder( ) ;

            oStringBuilder.Append(oXmlTextReader.ReadOuterXml( ) ) ;
            while (oXmlTextReader.Read()) 
            {
                oStringBuilder.Append(oXmlTextReader.ReadOuterXml( ) ) ;
            }
            wbWebBrowser.Navigate(oStringBuilder.ToString());
        }