DataGridViewCellCollection.AddRange(DataGridViewCell[]) Yöntem

Tanım

Koleksiyona bir hücre dizisi ekler.

public:
 virtual void AddRange(... cli::array <System::Windows::Forms::DataGridViewCell ^> ^ dataGridViewCells);
public virtual void AddRange (params System.Windows.Forms.DataGridViewCell[] dataGridViewCells);
abstract member AddRange : System.Windows.Forms.DataGridViewCell[] -> unit
override this.AddRange : System.Windows.Forms.DataGridViewCell[] -> unit
Public Overridable Sub AddRange (ParamArray dataGridViewCells As DataGridViewCell())

Parametreler

dataGridViewCells
DataGridViewCell[]

Koleksiyona eklenecek nesne dizisi DataGridViewCell .

Özel durumlar

dataGridViewCells, null değeridir.

Buna sahip DataGridViewCellCollection olan satır zaten bir DataGridView denetime ait.

-veya- içindeki dataGridViewCells en az bir değer şeklindedir null.

-veya- içindeki dataGridViewCells en az bir hücre zaten bir DataGridViewRowöğesine ait.

-veya- içindeki dataGridViewCells en az iki değer aynı DataGridViewCellöğesine başvurulardır.

Açıklamalar

Satırı denetime eklemeden önce hücrelerle doldurmak DataGridViewRow için DataGridView bu yöntemi kullanın. Bir denetime satırı eklediğinizde, içerdiği hücre sayısı her zaman denetimdeki sütun sayısıyla eşleşir, bu nedenle bu yöntem artık yararlı olmaz.

Şunlara uygulanır

Ayrıca bkz.