
Hello
When we change value of Unit Price manually, it re-calculates totals section
What I'm trying to achieve is to trigger totals re-calculation from an extension. Unit price gets updated by
[EventSubscriber(ObjectType::Table, Database::"Sales Line", 'OnAfterValidateEvent', 'Markup (LCY)', false, false)]
local procedure OnMarkupLCYChanged(var Rec: Record "Sales Line")
var
FieldNo: Integer;
begin
NewPrice := any number
Rec.Validate("Unit Price", NewPrice);
end; Hi,
Please visit the Page ID 46 and check the below code as per image, you will understand how its calculating.