I add an Xelement
to a parent Xelement
:
rootElement.Add(schemaRootTag);
The new XML element has an empty xmlns
attribute like: xmlns=""
.
Any ideas?
This has been asked here before. It's all to do with how you create the XElement: https://stackoverflow.com/a/12039383/616304