DataGridViewColumnCollection.Contains メソッド
定義
指定した列がコレクション内にあるかどうかを判断します。Determines whether the given column is in the collection.
オーバーロード
Contains(String) |
コレクションに、指定した名前によって参照される列が格納されているかどうかを判断します。Determines whether the collection contains the column referred to by the given name. |
Contains(DataGridViewColumn) |
指定した列がコレクションに格納されているかどうかを確認します。Determines whether the collection contains the given column. |
Contains(String)
コレクションに、指定した名前によって参照される列が格納されているかどうかを判断します。Determines whether the collection contains the column referred to by the given name.
public:
virtual bool Contains(System::String ^ columnName);
public virtual bool Contains (string columnName);
abstract member Contains : string -> bool
override this.Contains : string -> bool
Public Overridable Function Contains (columnName As String) As Boolean
パラメーター
- columnName
- String
検索する列の名前。The name of the column to look for.
戻り値
列がコレクションに格納されている場合は true
。それ以外の場合は false
。true
if the column is contained in the collection; otherwise, false
.
例外
columnName
は null
です。columnName
is null
.
注釈
列の名前は、 DataGridViewColumn.Nameプロパティによって示されます。The name of a column is indicated by the DataGridViewColumn.Name property.
こちらもご覧ください
Contains(DataGridViewColumn)
指定した列がコレクションに格納されているかどうかを確認します。Determines whether the collection contains the given column.
public:
virtual bool Contains(System::Windows::Forms::DataGridViewColumn ^ dataGridViewColumn);
public virtual bool Contains (System.Windows.Forms.DataGridViewColumn dataGridViewColumn);
abstract member Contains : System.Windows.Forms.DataGridViewColumn -> bool
override this.Contains : System.Windows.Forms.DataGridViewColumn -> bool
パラメーター
- dataGridViewColumn
- DataGridViewColumn
検索対象の DataGridViewColumn。The DataGridViewColumn to look for.
戻り値
指定された列がコレクション内に存在する場合は true
。それ以外の場合は false
。true
if the given column is in the collection; otherwise, false
.