語言

WebBaseEventCollection.Item[Int32] 屬性

定義

取得 WebBaseEvent 指定索引的物件。

public:
 property System::Web::Management::WebBaseEvent ^ default[int] { System::Web::Management::WebBaseEvent ^ get(int index); };
public System.Web.Management.WebBaseEvent this[int index] { get; }
member this.Item(int) : System.Web.Management.WebBaseEvent
Default Public ReadOnly Property Item(index As Integer) As WebBaseEvent

參數

index
Int32

你想取得物件 WebBaseEvent 的集合索引。

屬性值

指定索引的 WebBaseEvent 物件。

例外狀況

指定的索引不在集合範圍內。

範例

以下程式碼範例說明如何使用該 Item[] 屬性。

// Get the event with the specified index.
public static WebBaseEvent GetItem(int index)
{
    return events[index];
}
' Get the event with the specified index.
Public Shared Function GetItem(ByVal index _
As Integer) As WebBaseEvent
    Return events(index)

End Function 'GetItem

適用於

另請參閱