Hi,
I have a small question concerning the XPathNavigator.
The msdn documentation shows the Evaluate method can be casted,
so I used (m_vocabulary is an XPathNavigator):
XPathExpression xpCountExpr =
m_vocabulary.Compile("count(//[EMAIL PROTECTED]'label']/[EMAIL
PROTECTED]'constructor']/d-param)");
int nrp = (int)m_vocabulary.Evaluate(xpCountExpr);
But that did not work: I got a castexception in the line following on
the "int npr" assignment. (Other similar pieces of code had the same
effect).
So now I changed the code into:
int nrp = Int32.Parse(m_vocabulary.Evaluate(xpCountExpr).ToString());
and this works correctly.
Is this because of my misunderstanding of the documentation or due to a
bug or unfinished code in mono?
Regards,
Kris
--
Kris Luyten
Expertisecentrum Digitale Media - Limburgs Universitair Centrum
Wetenschapspark 2 3590 Diepenbeek (Belgium)
tel.: +32 (0)11 268411
email: [EMAIL PROTECTED]
PGP-key: http://lumumba.luc.ac.be/kris/kris-pub.txt
homepage: http://lumumba.luc.ac.be/kris/
_______________________________________________
Mono-list maillist - [EMAIL PROTECTED]
http://lists.ximian.com/mailman/listinfo/mono-list