checkbox changes not firing update dataset

DavidT_macktool

Well-known member
Joined
Oct 21, 2004
Messages
502
Location
Indiana
Programming Experience
3-5
Using a standard DataForm wizard form in single record format the -bit- field of my SQL table is represented by a checkbox. Changing the state of this checkbox and hitting the update button does not update the dataset. It goes thru the update procedure, but the getchanges method value is nothing, so no dataset update is performed.

Changes to any non-bit fields (textbox) will fire the update dataset method - so the dataset can be updated with the current code. Is there some way to get changes to the checkbox recognized by the getchanges function?
Currently objDataSetChanges is nothing in the code below when the checkbox is changed.

the checkbox is named - editOutside_Process
the databindings are:
(DataBindings)
(Advanced)
CheckAlign - (None)
Checked - (None) - should be set to dsOperations21 - Operations.outsideprocess
CheckState - (None)
Tag - (None)
Text - dsOperations21 - Operations.outsideprocess


The Update button fires this:

Try
Me.UpdateDataSet()
Catch eUpdate As System.Exception
System.Windows.Forms.MessageBox.Show(eUpdate.Message)
EndTry



PublicSub UpdateDataSet()
Dim objDataSetChanges As Mack.dsOperations2 = New Mack.dsOperations2
Me.BindingContext(DsOperations21, "Operations").EndCurrentEdit()
objDataSetChanges = CType(DsOperations21.GetChanges, Mack.dsOperations2)
If (Not (objDataSetChanges) IsNothing) Then
Try
Me.UpdateDataSource(objDataSetChanges)
DsOperations21.Merge(objDataSetChanges)
DsOperations21.AcceptChanges()
Catch eUpdate As System.Exception
Throw eUpdate
EndTry
EndIf
EndSub


figured it out... after seeing the databindings...
David
 
Last edited:
Top Bottom