SiteMapNode.Item[String] 屬性
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
從集合中取得或設定自訂屬性 Attributes ,或根據指定的鍵值設定資源字串。
public:
virtual property System::String ^ default[System::String ^] { System::String ^ get(System::String ^ key); void set(System::String ^ key, System::String ^ value); };
public virtual string this[string key] { get; set; }
member this.Item(string) : string with get, set
Default Public Overridable Property Item(key As String) As String
參數
- key
- String
一個用來識別要取回屬性或資源字串的字串。
屬性值
一個由 ;否則 key的 null自訂屬性或資源字串。
例外狀況
該節點為唯讀。
備註
這個 Item[] 屬性是一個索引器,首先判斷追蹤物件 SiteMapNode 的提供者是否支援本地化。 若是如此,則 Item[] 稱為
GetImplicitResourceString 方法,傳遞參數 key 。 若未回傳本地化文字,呼叫Item[]
若未回傳本地化文字,或提供者不支援本地化,則 Item[] 嘗試 Attributes 使用指定的 key。