title: C# XML Serilization & Appending new data
body: <p>I am trying to create an XML file with the following structure</p>
  
  <p><a href="https://i.stack.imgur.com/3mySW.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/3mySW.png" alt="enter image description here"></a></p>
  
  <p>However, this is what I get (one line):</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;&lt;!--This file is generated by the program.--&gt;&lt;root&gt;&lt;OFBM time="9:15" date="22.06.2016"&gt;&lt;folder&gt;file:///C:/Program Files (x86)/Cisco/Cisco AnyConnect Secure Mobility Client&lt;/folder&gt;&lt;folder&gt;file:///C:/Arduino223&lt;/folder&gt;&lt;/OFBM&gt;&lt;/root&gt;
  </code></pre>
  
  <p>My code:</p>
  
  <pre><code>public void CreateXML()
          {
              XmlWriter writer = XmlWriter.Create(@"C:\Users\Alek\Dropbox\D\Debug\product.xml");
  
              writer.WriteStartDocument();
  
              writer.WriteComment("This file is generated by the program.");
  
              writer.WriteStartElement("root");
              writer.WriteStartElement("OFBM");
              writer.WriteAttributeString("time", "9:15");
              writer.WriteAttributeString("date", "22.06.2016");
              writer.WriteElementString("folder", @"file:///C:/Program Files (x86)/Cisco/Cisco AnyConnect Secure Mobility Client");
              writer.WriteElementString("folder", @"file:///C:/Arduino223");
              writer.WriteEndElement();
              writer.WriteEndElement();
              writer.WriteEndDocument();
              writer.Flush();
              writer.Close();
          }
  </code></pre>
  
  <p>How do I also append new data? Instead of creating a new XML each time.</p>