PropertyDictionary.TryGetPropertyValue 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
決定一個表示要取得屬性的值。
多載
| 名稱 | Description |
|---|---|
| TryGetPropertyValue(String, Object) |
取得一個表示要取得屬性的值。 |
| TryGetPropertyValue<T>(String, T) |
透過項目清單取得一個表示要取得屬性的值。 |
TryGetPropertyValue(String, Object)
取得一個表示要取得屬性的值。
public:
virtual bool TryGetPropertyValue(System::String ^ name, [Runtime::InteropServices::Out] System::Object ^ % value);
public bool TryGetPropertyValue(string name, out object value);
abstract member TryGetPropertyValue : string * obj -> bool
override this.TryGetPropertyValue : string * obj -> bool
Public Function TryGetPropertyValue (name As String, ByRef value As Object) As Boolean
參數
- name
- String
一個字串輸入,代表屬性名稱。
- value
- Object
一個財產的物件。
傳回
true若某值表示要取得的屬性;否則,。 false
實作
適用於
TryGetPropertyValue<T>(String, T)
透過項目清單取得一個表示要取得屬性的值。
public:
generic <typename T>
virtual bool TryGetPropertyValue(System::String ^ name, [Runtime::InteropServices::Out] T % value);
public bool TryGetPropertyValue<T>(string name, out T value);
abstract member TryGetPropertyValue : string * 'T -> bool
override this.TryGetPropertyValue : string * 'T -> bool
Public Function TryGetPropertyValue(Of T) (name As String, ByRef value As T) As Boolean
類型參數
- T
物品的通用價值。
參數
- name
- String
一個字串值,代表要取得的屬性名稱。
- value
- T
項目的指定值。
傳回
true若某值表示使用項目列表取得的屬性;否則,。 false