S
scott
I have a simple Windows form bound to one SQL Server table using the
BindingSource control. I would like to use the BindingNavigator
control to navigate through records. One text box holds a required
field. When I click the AddNew button on the BindingNavigator, a new
record is added to the DataTable and all fields are cleared on the
form. If I happen to press the AddNew button again and the required
text field remains empty, a System.Data.NoNullAllowedException occurs.
How do I cancel the addition of the new row if the required field is
empty?
Thanks!
Scott Adams
BindingSource control. I would like to use the BindingNavigator
control to navigate through records. One text box holds a required
field. When I click the AddNew button on the BindingNavigator, a new
record is added to the DataTable and all fields are cleared on the
form. If I happen to press the AddNew button again and the required
text field remains empty, a System.Data.NoNullAllowedException occurs.
How do I cancel the addition of the new row if the required field is
empty?
Thanks!
Scott Adams