Język

DataGridViewCellCollection.Item[] Właściwość

Definicja

Pobiera lub ustawia element w podanej lokalizacji. W języku C#ta właściwość jest indeksatorem DataGridViewCellCollection klasy .

Przeciążenia

Nazwa Opis
Item[Int32]

Pobiera lub ustawia komórkę w podanej lokalizacji indeksu. W języku C#ta właściwość jest indeksatorem DataGridViewCellCollection klasy .

Item[String]

Pobiera lub ustawia komórkę w kolumnie o podanej nazwie. W języku C#ta właściwość jest indeksatorem DataGridViewCellCollection klasy .

Item[Int32]

Źródło:
DataGridViewCellCollection.cs
Źródło:
DataGridViewCellCollection.cs
Źródło:
DataGridViewCellCollection.cs
Źródło:
DataGridViewCellCollection.cs
Źródło:
DataGridViewCellCollection.cs

Pobiera lub ustawia komórkę w podanej lokalizacji indeksu. W języku C#ta właściwość jest indeksatorem DataGridViewCellCollection klasy .

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

Parametry

index
Int32

Indeks na podstawie zera komórki, który ma być pobierany lub ustawiany.

Wartość właściwości

Przechowywany DataGridViewCell w danym indeksie.

Wyjątki

Określona wartość podczas ustawiania tej właściwości to null.

Określona komórka podczas ustawiania tej właściwości już należy do kontrolki DataGridView .

— lub —

Określona komórka podczas ustawiania tej właściwości już należy do DataGridViewRow.

index wartość jest mniejsza niż 0.

— lub —

index jest równa lub większa niż liczba komórek w kolekcji.

Zobacz też

Dotyczy

Item[String]

Źródło:
DataGridViewCellCollection.cs
Źródło:
DataGridViewCellCollection.cs
Źródło:
DataGridViewCellCollection.cs
Źródło:
DataGridViewCellCollection.cs
Źródło:
DataGridViewCellCollection.cs

Pobiera lub ustawia komórkę w kolumnie o podanej nazwie. W języku C#ta właściwość jest indeksatorem DataGridViewCellCollection klasy .

public:
 property System::Windows::Forms::DataGridViewCell ^ default[System::String ^] { System::Windows::Forms::DataGridViewCell ^ get(System::String ^ columnName); void set(System::String ^ columnName, System::Windows::Forms::DataGridViewCell ^ value); };
public System.Windows.Forms.DataGridViewCell this[string columnName] { get; set; }
member this.Item(string) : System.Windows.Forms.DataGridViewCell with get, set
Default Public Property Item(columnName As String) As DataGridViewCell

Parametry

columnName
String

Nazwa kolumny, w której ma być pobierana lub ustawiana komórka.

Wartość właściwości

Przechowywany DataGridViewCell w kolumnie o podanej nazwie.

Wyjątki

columnName nie jest zgodna z nazwą żadnych kolumn w kontrolce.

Określona wartość podczas ustawiania tej właściwości to null.

Określona komórka podczas ustawiania tej właściwości już należy do kontrolki DataGridView .

— lub —

Określona komórka podczas ustawiania tej właściwości już należy do DataGridViewRow.

Zobacz też

Dotyczy