ALAppExtensions
ALAppExtensions copied to clipboard
[Extensibility Enhancement] Page 300 - Ship-to Address - OnBeforeOnNewRecord/OnAfterOnNewRecord
Add the current page Rec to these events on Page 300 "Ship-to Address". Currently these events don't allow us to default additional fields from the Customer; I'm having to use OnBeforeInsert instead and get the Customer again.
trigger OnNewRecord(BelowxRec: Boolean)
var
Customer: Record Customer;
begin
if not Customer.Get(GetFilterCustNo) then
exit;
OnBeforeOnNewRecord(Rec, Customer); // Added Rec
Validate(Name, Customer.Name);
Validate(Address, Customer.Address);
Validate("Address 2", Customer."Address 2");
"Country/Region Code" := Customer."Country/Region Code";
City := Customer.City;
County := Customer.County;
"Post Code" := Customer."Post Code";
Validate(Contact, Customer.Contact);
OnAfterOnNewRecord(Rec, Customer); // Added Rec
end;
[IntegrationEvent(false, false)]
local procedure OnAfterOnNewRecord(var ShipToAddr: Record "Ship-to Address"; var Customer: Record Customer)
begin
end;
[IntegrationEvent(false, false)]
local procedure OnBeforeOnNewRecord(var ShipToAddr: Record "Ship-to Address"; var Customer: Record Customer)
begin
end;
Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. We will update this issue with information about availability. Please do not reply to this, as we do not monitor closed issues. If you have follow-up questions or requests, please create a new issue where you reference this one.