DomainUpDown.DomainUpDownItemCollection クラスの Remove メソッドまたは RemoveAt メソッドを呼び出すことにより、Windows フォームの DomainUpDown コントロールから項目を削除できます。 Remove メソッドは、特定の項目を削除します。RemoveAt メソッドは、指定された位置の項目を削除します。
項目を削除するには
DomainUpDown.DomainUpDownItemCollection クラスの Remove メソッドを使用して、指定した名前の項目を削除します。
DomainUpDown1.Items.Remove("noodles")
domainUpDown1.Items.Remove("noodles");
domainUpDown1->Items->Remove("noodles");
または
RemoveAt メソッドを使用して、指定した位置の項目を削除します。
' Removes the first item in the list. DomainUpDown1.Items.RemoveAt(0)
// Removes the first item in the list. domainUpDown1.Items.RemoveAt(0);
// Removes the first item in the list. domainUpDown1->Items->RemoveAt(0);
参照
参照
DomainUpDown コントロールの概要 (Windows フォーム)
DomainUpDown.DomainUpDownItemCollection.Remove
DomainUpDown.DomainUpDownItemCollection.RemoveAt