DarkW1nter
DarkW1nter

Reputation: 2841

show formatted xml in textbox

I've been searching for a way to show formatted xml in a textbox, everything I've found so far points towards reading in xml from a file and formatting that, however I want to show xml which is held in a database field.

The idea is that a user will have records returned to a gridview, the gridview will show everything apart from the xml message due to its size. They can then select the record and show the xml on a pop-up form.

I have the xml passed to the pop-up form, just not sure how to handle it. Any ideas welcome.

Upvotes: 14

Views: 25802

Answers (1)

DarkW1nter
DarkW1nter

Reputation: 2841

Got round it by using

xmlOut = System.Xml.Linq.XDocument.Parse(txtXml).ToString();

Upvotes: 38

Related Questions