Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
20
Row editing on XamDataGrid
posted

Hi,

I'd like to be able to edit a single row on a datagrid so that;

  • I can edit any cells within that row
  • The cells in other rows are disabled until I either save or cancel the changes to the row I am editing
  • I cannot save my changes to a row if any of the cells in the row are invalid
  • An event is raised when I cancel or save changes to a row (not an individual cell)

What I am looking for is to have edit, save and cancel buttons in an unbound field on each row in the data grid.  The user can use these buttons (or double click a cell to start editing a row) to make changes to a single row at a time.

Is this possible?

Matt

  • 30945
    Suggested Answer
    Offline posted

    Hello Matt,

     

    I have created a sample application that demostras an approach for implementing the functionality that you want. I use a style for the DataRecordPresenter with MultiDataTrigger in order to disable the records without the record that have cell which is in edit mode. I have added the edit, save and cancel buttons in a template for an UnboundField which is the last field in the XamDataGrid. You can use my custom approach as basis in order to implement the functionality that you want.

     

    If you require any further clarifications please do not hesitate to ask.

     

    Sincerely,

    Krasimir

    Developer Support Engineer

    Infragistics

    www.infragistics.com/support

    RecordEditing.zip