I have this XML
<SENDERS VERSION="V3.0.4" xsi:noNamespaceSchemaLocation="SENDERS.xd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<SECTION>
</SECTION>
</SENDERS>
I am trying to parse it and find the element SECTION with the xsi namespace using the following code
var xdoc = XDocument.Parse(myxml);
var ns = xdoc.Root.GetNamespaceOfPrefix("xsi");
var section = xdoc.Element(ns + "SECTION");
Usually I do it this way but this time section is always null. Am I doing something wrong?