Xml to Text Convert

Slelveentipse

New Member
I would like to write something in C# that takes Xml and converts it to plain text. \[code\]<note> <to>Tove</to> <from>Jani</from> <heading>Reminder</heading> <body>Don't forget me this weekend!</body></note>\[/code\]Would become:\[code\]To ToveFrom JaniHeading ReminderBody don't forget me this weekend!\[/code\]Is there any thing already like this? and how would i go about doing this?This is just ruffly the idea im going for still needs lots of work:\[code\]private void dataGridViewResult_SelectionChanged(object sender, EventArgs e) { if (this.dataGridViewResult.SelectedRows.Count > 0) { XslCompiledTransform xslt = new XslCompiledTransform(); xslt.Load("SQL"); //.xml xslt.Transform("SQL","SQL"); //.xml, .html this.richTextBoxSQL.Text = this.dataGridViewResult.SelectedRows[0].Cells["SQL"].Value.ToString(); } }\[/code\]
 
Back
Top