Subject is probably too short to explain this ...
I am writing XML files without any namespace elements for any application. That part that I can’t change. But now I'm going to expand these files with my application name names, and I would like to put them in a different namespace. For this, the result should look like this:
<doc xmlns:x="urn:my-app-uri">
<a>existing element name</a>
<x:addon>my additional element name</x:addon>
</doc>
I used the XmlNamespaceManager and added my URI with the prefix "x" to it. I also passed it to each CreateElement element for my additional element names. But the closest I can get is:
<doc>
<a>existing element name</a>
<addon xmlns="urn:my-app-uri">my additional element name</addon>
</doc>
Or maybe,
<x:addon xmlns:x="urn:my-app-uri">my additional element name</x:addon>
, , URI , , .
XML .NET?