次の方法で共有


XPathNavigator.GetAttribute Method

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Gets the value of the attribute with the specified local name and namespace URI.

Namespace:  System.Xml.XPath
Assembly:  System.Xml.XPath (in System.Xml.XPath.dll)

Syntax

'Declaration
Public Overridable Function GetAttribute ( _
    localName As String, _
    namespaceURI As String _
) As String
public virtual string GetAttribute(
    string localName,
    string namespaceURI
)

Parameters

  • namespaceURI
    Type: System.String
    The namespace URI of the attribute.

Return Value

Type: System.String
A String that contains the value of the specified attribute; String.Empty if a matching attribute is not found, or if the XPathNavigator is not positioned on an element node.

Version Information

Silverlight

Supported in: 5, 4

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.