Hi,
I have a custom screen , I need to get the total amount of the header level based on the sum of line amount of the grid level.

as per above screenshot, I have taken the multiplication of A and B to the C column. Likewise I have to get the value in C column for each row which were added in the grid, Then I need to pass the sum of C column to the D field in the header level. for that I have added below code snippet in rowinserting event handler but it’s not working, only the C value is calculated.
decimal? amount = this.APProformaItems.Select().FirstTableItems.ToList().Select(x => x.Amount * x.ProFormaQty).Sum();
// Acuminator disable once PX1048 RowChangesInEventHandlersAllowedForArgsOnly [Justification]
item.DetailTotal = amount;
decimal? LineAmount = row.ProFormaQty * row.Amount;
row.TotalAmount = LineAmount;
ApproformaItems = view for the grid
Can someone suggest a way to achieve this?
Thank you.