How to write a namespace in an Element with XmlWriter
<p>I'm changing my code from vbs to C#, but i have a problem with XMLwriter, how to use XML write to get such output in XML.file :  ??</p>

<p>I have code like this :</p>

<pre><code>using (XmlWriter writer = XmlWriter.Create(Form1.systemDrive + "\\unattend.xml"))
{
    writer.WriteStartDocument();
    writer.WriteProcessingInstruction("xml", "version='1.0' encoding='UTF-8'");
    writer.WriteStartElement("unattend");
    writer.WriteAttributeString("xmlns", "urn:schemas-microsoft-com:unattend"); // &lt;&lt;&lt;&lt;&lt;&lt;&lt; Gives an error 
</code></pre>

<p>....</p>