BindingNavigator.AddNewItem Właściwość

Definicja

Pobiera lub ustawia ToolStripItem element reprezentujący przycisk Dodaj nowy .

public:
 property System::Windows::Forms::ToolStripItem ^ AddNewItem { System::Windows::Forms::ToolStripItem ^ get(); void set(System::Windows::Forms::ToolStripItem ^ value); };
[System.ComponentModel.TypeConverter(typeof(System.ComponentModel.ReferenceConverter))]
public System.Windows.Forms.ToolStripItem AddNewItem { get; set; }
[System.ComponentModel.TypeConverter(typeof(System.ComponentModel.ReferenceConverter))]
public System.Windows.Forms.ToolStripItem? AddNewItem { get; set; }
[<System.ComponentModel.TypeConverter(typeof(System.ComponentModel.ReferenceConverter))>]
member this.AddNewItem : System.Windows.Forms.ToolStripItem with get, set
Public Property AddNewItem As ToolStripItem

Wartość właściwości

Element ToolStripItem reprezentujący przycisk Dodaj nowy dla elementu BindingSource. Wartość domyślna to null.

Atrybuty

Uwagi

Po ustawieniu AddNewItem właściwość generuje procedurę Click obsługi zdarzeń dla przycisku Dodaj nowy . Ta procedura obsługi zdarzeń wywołuje metodę po kliknięciu AddNew przycisku Dodaj nowy w czasie wykonywania.

Ta właściwość jest null taka, jeśli nie została wcześniej ustawiona i jest dostępna przed AddStandardItems niejawnym lub jawnym wywołaniem metody.

Kontrolka BindingNavigator wyłączy przycisk Dodaj nowy , jeśli BindingSource właściwość to null lub AllowNew właściwość to false.

W domyślnej implementacji ta właściwość reprezentuje kontrolkę typu ToolStripButton.

Dotyczy

Zobacz też