取得用於擷取對應於指定擴充名稱之屬性執行個體的索引子 (Indexer)。
elem.Attribute[{namespaceName}attribName]
屬性值/傳回值
XAttribute Item(String expandedName) 型別的索引子。 如果沒有具有指定之名稱的屬性,這個索引子會採用指定之屬性的擴充名稱,並傳回對應的 XAttribute 或 null。
備註
這個屬性等同於 System.Xml.Linq.XElement 類別的 Attribute 方法。
取得用於擷取對應於指定擴充名稱之屬性執行個體的索引子 (Indexer)。
elem.Attribute[{namespaceName}attribName]
XAttribute Item(String expandedName) 型別的索引子。 如果沒有具有指定之名稱的屬性,這個索引子會採用指定之屬性的擴充名稱,並傳回對應的 XAttribute 或 null。
這個屬性等同於 System.Xml.Linq.XElement 類別的 Attribute 方法。