XML Browser in C# Windows Form



In this article we will see how to show dataset data in xmlbrowser.


In this article I’m using the xmlbrowser control from third party. This control will show the data of dataset in xml format as well you can load any existing xml document also. In windows form it’s not easy to show xml data while in web application browser only show the content of xml file.

Here I had just given this one sample example to show dataset data into xml format. I found this XmlRender.dll while google search. This XmlRender.dll file contain only XmlBrowser control. How to show our data in xml format we will see step by step.

Step 1:

Create new windows form application and add reference to this XmlRender.dll.

Step 2:

Now we have added reference write now we can access the control of XmlRender.dll file. Just create new XmlBrowser control at runtime.

XmlRender.XmlBrowser xml=new XmlRender.XmlBrowser();

Set some properties of this xmlbrowser control now in Designer.cs page

Step 3:

Just now get your Dataset object and set the XmlBrowser’s XmlText property to ds.GetXml() method which will display output as bellow.


Here we have seen some Xmlbrowser control to show our data in xml format. You can show xmldocument also in this browser using browser.XmlDocument property.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s