DataGridViewComboBoxCell.ObjectCollection.IList.Add(Object) DataGridViewComboBoxCell.ObjectCollection.IList.Add(Object) DataGridViewComboBoxCell.ObjectCollection.IList.Add(Object) Method

定義

將物件加入至集合。Adds an object to the collection.

 virtual int System.Collections.IList.Add(System::Object ^ item) = System::Collections::IList::Add;
int IList.Add (object item);
Function Add (item As Object) As Integer Implements IList.Add

參數

item
Object Object Object

要新增至集合的物件。The object to add to the collection.

傳回

要插入新元素的位置。The position in which to insert the new element.

實作

例外狀況

儲存格的 DataSource 屬性值不為 nullThe cell's DataSource property value is not null.

儲存格位於共用資料列中。The cell is in a shared row.

備註

這個成員是明確介面成員實作,This member is an explicit interface member implementation. 只有在 DataGridViewComboBoxCell.ObjectCollection 執行個體轉換成 IList 介面時,才能使用這個成員。It can be used only when the DataGridViewComboBoxCell.ObjectCollection instance is cast to an IList interface.

適用於

另請參閱