ListSortDescriptionCollection.IList.Insert(Int32, Object) 方法

定義

在指定的索引位置,插入項目至集合之中。

 virtual void System.Collections.IList.Insert(int index, System::Object ^ value) = System::Collections::IList::Insert;
void IList.Insert (int index, object value);
void IList.Insert (int index, object? value);
abstract member System.Collections.IList.Insert : int * obj -> unit
override this.System.Collections.IList.Insert : int * obj -> unit
Sub Insert (index As Integer, value As Object) Implements IList.Insert

參數

index
Int32

要在集合中取得或設定之 ListSortDescription 的以零起始的索引。

value
Object

要插入集合中的項目。

實作

例外狀況

在所有情況下。

備註

ListSortDescriptionCollection因為類別會實作 System.Collections.IList 介面,所以必須有 IList.Insert 方法。 不過,因為 ListSortDescriptionCollection 類別代表唯讀集合,所以將專案插入集合是無效的作業。

適用於