Hi,
i've got the problem where the user is typing some data in a cell and then clicks the save-button. While the cell stays in EditMode, the value will not be updated and in this case the value will not be saved.
Is there any possibility to change the value of a databound property on typing, so that the user can type something and then click save, and the value would be saved?
thanks
Alexander Kant
Yeah, that works!
Thanks a lot, and have a nice day. :-)
One thing that you might try is to handle the CellChanged event (or since you have a derived version overriding the OnCellChanged method). Then you could do something like:
e.Cell.Record.SetCellValue(e.Cell.Field, e.Editor.Value, true);
Hello Stefan,
executing the CommitChangesToAllRecords command in the save commands was one of my first ideas, but i got the problem, that i've got a lot of different editors with save buttons in the whole application (some of the editors got multiple grids on it) and i'm afraid of implementing the ExecuteCommand call in every save button for every grid. Not to mention that i've got to implement this for each new grid i'll add to an editor.
Also i've inherited the XamDataGrid. So my intention was, if there's any kind of setting i could put in my base grid, so that the property of the business object bound to the cell would be updated immediatly while typing in it. With some solution like this, i wouldn't have to implement CommitChangesToAllRecords for each new grid or even each new editor i will create in the future.
Maybe there's some "clean" solution like a setting that would force the grid to update the property's value on typing.
Hello Alex,
I apologize for the late reply, but please note, we are making efforts to ensure all posts are addressed by an Infragistics expert. I have been looking trough your post and it like I am missing something, since when you CommitChanges on the editor's value changed you get the same functionality as setting the UpadateMode property to UpdateMode.OnCellChange. I have created a sample project where there is a “Save” button which determines when the changes will be saved to the DataSource. Please let me know if this meets all your requirements or you need any further clarifications on this matter.
Looking forward for your reply.
i still need some advice. Could anyone help me please?
Thanks, Alex