ActivityCollection.Item[] 屬性

定義

按照名稱或索引取得 Activity 中的 ICollection 項目。

多載

Item[String]

根據為唯一索引鍵的字串取得 ICollection 中的活動。

Item[Int32]

根據索引取得或設定 ICollection 中的活動。

Item[String]

根據為唯一索引鍵的字串取得 ICollection 中的活動。

public:
 property System::Workflow::ComponentModel::Activity ^ default[System::String ^] { System::Workflow::ComponentModel::Activity ^ get(System::String ^ key); };
public System.Workflow.ComponentModel.Activity this[string key] { get; }
member this.Item(string) : System.Workflow.ComponentModel.Activity
Default Public ReadOnly Property Item(key As String) As Activity

參數

key
String

ICollection 中活動的唯一識別碼。

屬性值

Activity

ActivityICollection 成員,為呼叫中指定的 ICollection 中的索引鍵。

備註

如果含指定索引鍵的 Activity 中沒有 ICollection,則會引發例外狀況。

適用於

Item[Int32]

根據索引取得或設定 ICollection 中的活動。

public:
 property System::Workflow::ComponentModel::Activity ^ default[int] { System::Workflow::ComponentModel::Activity ^ get(int index); void set(int index, System::Workflow::ComponentModel::Activity ^ value); };
public System.Workflow.ComponentModel.Activity this[int index] { get; set; }
member this.Item(int) : System.Workflow.ComponentModel.Activity with get, set
Default Public Property Item(index As Integer) As Activity

參數

index
Int32

ICollection 中以零起始的索引。

屬性值

Activity

ICollection 的成員活動,其在 ICollection 中的索引已在呼叫中指定。

實作

例外狀況

indexIList 中不是有效的索引。

屬性已設定,而且 IList 是唯讀的。

嘗試設定為不是 ObjectActivity

適用於