Completed
Last Updated: 09 Aug 2022 07:44 by ADMIN
Release 3.6.0 (14 Sep 2022) (R3 2022)
Nadezhda
Created on: 12 Oct 2021 09:07
Category: Grid
Type: Bug Report
7
Field and Value properties from GridCommandEventArgs are null
Field and Value properties from GridCommandEventArgs don't populate in Incell editing. Their value is always null and thus I cannot get information for the edited field.
2 comments
ADMIN
Dimo
Posted on: 24 Nov 2021 09:14

Hi Jeff,

Yes, you can get the edited field from the Grid state (also see the GridState Class API reference):

async Task UpdateItem(GridCommandEventArgs args)
{
    var state = MyGrid.GetState();
    var editField = state.EditField;
    var editItem = args.Item as Product;
    var originalItem = state.OriginalEditItem;

    var newValue = editItem.GetType().GetProperty(editField).GetValue(editItem, null);
    var oldValue = originalItem.GetType().GetProperty(editField).GetValue(originalItem, null);
}

Regards,
Dimo
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

JeffVisibilEDI
Posted on: 19 Nov 2021 20:35

Is there a known workaround?

 

TIA