35 references to Add
DesignSurface (1)
MainForm.cs (1)
367
richTextBox.DataBindings.
Add
(new Binding("Text", bindingSource, "Text", true, DataSourceUpdateMode.OnPropertyChanged));
System.Windows.Forms (1)
System\Windows\Forms\DataBinding\ControlBindingsCollection.cs (1)
158
Add
(binding);
System.Windows.Forms.Tests (33)
System\Windows\Forms\BindingContextTests.cs (1)
991
control.DataBindings.
Add
(binding);
System\Windows\Forms\ControlBindingsCollectionTests.cs (27)
74
collection.
Add
(binding1);
75
collection.
Add
(binding2);
76
collection.
Add
(binding3);
79
collection.
Add
(binding4);
93
collection.
Add
(binding);
108
collection.
Add
(binding1);
109
collection.
Add
(binding2);
110
collection.
Add
(binding3);
111
collection.
Add
(binding4);
112
collection.
Add
(binding5);
241
Assert.Throws<ArgumentException>("PropertyName", () => collection.
Add
(new Binding("NoSuchProperty", new object(), "dataMember")));
256
collection.
Add
(binding);
258
Assert.Throws<ArgumentException>("binding", () => collection.
Add
(new Binding(nameof(Control.Text), new object(), "dataMember")));
272
Assert.Throws<ArgumentNullException>("dataBinding", () => collection.
Add
(null));
282
collection.
Add
(binding);
283
Assert.Throws<ArgumentException>("dataBinding", () => collection.
Add
(binding));
295
collection1.
Add
(binding);
296
Assert.Throws<ArgumentException>("dataBinding", () => collection2.
Add
(binding));
306
collection.
Add
(binding);
326
collection.
Add
(binding);
341
collection.
Add
(binding);
354
collection.
Add
(binding1);
369
collection1.
Add
(binding1);
370
collection2.
Add
(binding2);
384
collection.
Add
(binding);
401
collection.
Add
(binding);
414
collection.
Add
(binding);
System\Windows\Forms\ControlTests.Methods.cs (4)
1151
control.DataBindings.
Add
(new Binding("Text", new object(), "member"));
1599
control.DataBindings.
Add
(new Binding("Text", new object(), "member"));
1647
control.DataBindings.
Add
(binding);
6414
control.DataBindings.
Add
(new Binding("Text", new object(), "member"));
System\Windows\Forms\PropertyManagerTests.cs (1)
171
controlBindings.
Add
(cancelBinding);