XmlNode.NamespaceURI XmlNode.NamespaceURI XmlNode.NamespaceURI XmlNode.NamespaceURI Property

定義

取得這個節點的命名空間 URI。Gets the namespace URI of this node.

public:
 virtual property System::String ^ NamespaceURI { System::String ^ get(); };
public virtual string NamespaceURI { get; }
member this.NamespaceURI : string
Public Overridable ReadOnly Property NamespaceURI As String

屬性值

這個節點的命名空間 URI。The namespace URI of this node. 如果沒有命名空間 URI,則這個屬性傳回 String.Empty。If there is no namespace URI, this property returns String.Empty.

備註

這是在建立時指定的命名空間 URI。This is the namespace URI specified at creation time. 例如, NamespaceURI是 urn:元素<的範例 bk: book xmlns: bk = "urn: samples" >For example, NamespaceURI is urn:samples for the element <bk:book xmlns:bk= "urn:samples">

屬性不會從所附加的元素繼承其命名空間。An attribute does not inherit its namespace from the element it is attached to. 如果沒有明確指定命名空間的屬性,它就不會有命名空間。If an attribute is not explicitly given a namespace, it simply has no namespace.

適用於