You need to know what the namespace is. That will have been declared earlier, with something like:
xmlns:vs="http://some_url_here"
You can query using XNamespace
:
XNamespace vs = "http://some_url_here";
var names = doc.Descendants(vs + "Name")
.Select(x => (string) x)
.ToList();
The +
here is actually converting an XNamespace
and a string to an XName
.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…