共用方式為


ModelMemberCollection<TItemType, TKeyType>.Find 方法 (TKeyType)

在集合中搜尋具有指定索引鍵的項目,如果找到就傳回該項目。

命名空間:  Microsoft.Windows.Design.Model
組件:  Microsoft.Windows.Design.Interaction (在 Microsoft.Windows.Design.Interaction.dll 中)

語法

'宣告
Public Function Find ( _
    value As TKeyType _
) As TItemType
public TItemType Find(
    TKeyType value
)
public:
TItemType Find(
    TKeyType value
)
member Find : 
        value:'TKeyType -> 'TItemType 
public function Find(
    value : TKeyType
) : TItemType

參數

  • value
    型別:TKeyType
    要尋找之項目的索引鍵。

傳回值

型別:TItemType
具有指定索引鍵的 TItemType。如果找不到,這個方法會傳回 nullNull 參照 (即 Visual Basic 中的 Nothing)。

例外狀況

例外狀況 條件
ArgumentNullException

value 為 nullNull 參照 (即 Visual Basic 中的 Nothing)。

.NET Framework 安全性

請參閱

參考

ModelMemberCollection<TItemType, TKeyType> 類別

Find 多載

Microsoft.Windows.Design.Model 命名空間

其他資源

WPF 設計工具擴充性