hi,
i have an application in which A grid is there for binding companies Details and checkboxes and textboxes in the same form for binding those values of selected row of the grid..
when navigating from one row to other row in grid .if there are any changes made to textboxes or checkboxes we should enable save button and show a message like "Save changes."
i wrote the events for them in foreach loop
For Each gb As GroupBox In {gbBox1, gpbox2, gpBox3, gpBox4, gbbox5}
For Each ctrl As Control In gb.Controls
If TypeOf ctrl Is CheckBox Then
AddHandler CType(ctrl, CheckBox).CheckedChanged, AddressOf EnableButton
ElseIf TypeOf ctrl Is TextBox Then
AddHandler CType(ctrl, TextBox).TextChanged, AddressOf EnableButton
End If
Next
Next
Private Sub EnableButton()
BtnSave.Enabled = True
End Sub
here my problem is if checkbox is checked then button is enabling. but it should disable when checkbox is unchecked (i.e no changes made )
is there any way to get this ...
i am not using EDMX.