on my project i have a form in which i have TextBox
in some point of executing my program i want to put XML
string in my TextBox
- nothing complicated.
Problem lies in the format in which this XML
is being displayed in TextBox
which is:
<?xml version="1.0" encoding="utf-16" ?><IOTPMessage xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Element1>value</Element1><Element2>value</Element2><Element3>value</Element3></IOTPMessage>
I want it to look like proper XML
look like (with new lines, tabulators) which is easy to read :
<?xml version="1.0" encoding="utf-16" ?>
<IOTPMessage xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Element1>value</Element1>
<Element2>value</Element2>
<Element3>value</Element3>
</IOTPMessage>
The way i put XML
string to textBox:
TextBox someBox;
someBox.Append(XMLstring);
To be honest i don't even knew where to start - besides looking for proper articles or samples which i didn't find, maybe anyone of you can redirect me to somewhere where i can find solution?