FIX: XPathNavigator.MoveToNextNamespace with XPathNamespaceScope.Local (316808)
The information in this article applies to:
- Microsoft XML Classes (included with the .NET Framework 1.0)
This article was previously published under Q316808 SYMPTOMS If an XML node has two namespaces defined as follows:
<ns1:myElement xmlns:ns1='http://namespace1' xmlns:ns2='http://namespace2'><ns1:someElement/></ns1:myElement>
When you call the XPathNavigator.MoveToNextNamespace method with the input parameter of XPathNamespaceScope as XPathNamespaceScope.Local to navigate to the next namepace, an incorrect result is
returned. After you call the XPathNavigator.MoveToFirstNamespace(XPathNamespaceScope.Local) method, calling MoveToNextNamespace(XPathNamespaceScope.Local) returns false instead of moving to the next namespace.
RESOLUTION This problem occurs only with the XmlDocument class; to work around the problem, use the XPathDocument class. STATUS
This bug was corrected in Microsoft .NET Class Libraries 1.1.
Modification Type: | Major | Last Reviewed: | 9/18/2003 |
---|
Keywords: | kbbug KB316808 |
---|
|