I'm using the XmlDocument
class like this:
divisionsDoc.SelectSingleNode(
string.Format(@"Root/PoliticalDivisions/PoliticalDivision[upper-case(@Code)='{0}']", withCode.ToUpper()));
And this is resulting in the error:
Namespace Manager or XsltContext needed. This query has a prefix, variable, or user-defined function.
I gather this is due to the upper-case
XPath function, which I understand exists in XPath 2.0 and not 1.0 (from here, here, etc.)
MSDN doesn't specify the version of XPath it uses. I'm targeting .NET 4.5.1 -- wouldn't that be late enough to be using XPath 2.0? Or is that something that is defined elsewhere (outside of .NET)?
How can I find out what version of XPath is being targeted?
Please note, I'm aware of the work-around using translate('some text','abcdefghijklmnopqrstuvwxyz','ABCDEFGHIJKLMNOPQRSTUVWXYZ')
-- that's not what I'm asking.