When using a dataset with the UltraCalendarInfo.DataBindingsForAppointments, what determines when the Appointment data is committed/updated to bound dataset?
Most other infragistics controls such as the ultragrid have a property that determines when this update occurs ie ultragrid.updatemode.
The only time I have found that the update to the dataset from the ultracalendarinfo occurs is when the form containing the control is closed?
Thank you.
lyleh said:The only time I have found that the update to the dataset from the ultracalendarinfo occurs is when the form containing the control is closed?
I am speculating a bit here but if you came to this conclusion through experimenting with the "WinSchedule Database Demo" sample, it is possible you are confusing an update to the DataSet with the committing of those changes to the underlying DataTable. As mentioned in another reply to this post, any change to a bound data field results in an update to the DataSet. Those changes, however, are not committed to the underlying database unless the application causes it to happen. The "WinSchedule Database Demo" sample does in fact commit DataSet changes to the database when the form is closed; you can place a breakpoint in the FormClosing event if you want to trace through the sequence of events.
Hi Brian,
Thanks for the response, yes I am aware of the difference between the update to the dataset versus the update to the datatable. I am employing the dataset.haschanges method to determine that a tableAdapter.update needs to be invoked to update the datatable. What I am looking for is an event to indicate that the dataset has in fact had changes. I am working with your suggestion of an event handler for the datarow.changed event. I should be able to get that to work, although it currently generates an error (looping I think) indicating that a datareader is already open for that tableAdapter and needs to be closed. Probably need to suspend the datarow.event while invoking the tableAdapter.update. Thanks again, I will let you know of my success.
Brian, thanks again, I was successfull in using the datarow.changed event coupled with the judicious use of the AddHandler and RemoveHandler during the database update.
Thanks again.