[Event Request] Table 18 - Customer - OnBeforeGetCustNoOpenCard
Hi AL-Team, can you please add the following Publisher in GetCustNoOpenCard?
procedure GetCustNoOpenCard(CustomerText: Text; ShowCustomerCard: Boolean; ShowCreateCustomerOption: Boolean): Code[20]
var
Customer: Record Customer;
CustomerNo: Code[20];
NoFiltersApplied: Boolean;
CustomerWithoutQuote: Text;
CustomerFilterFromStart: Text;
CustomerFilterContains: Text;
begin
// NEW >>>
OnBeforeGetCustNoOpenCard(Rec,Customer);
// NEW <<<<
if CustomerText = '' then
exit('');
[IntegrationEvent(false, false)]
local procedure OnBeforeGetCustNoOpenCard(var Rec: Record Customer; var Customer: Record Customer)
begin
end;
What is the purpose of parameter Customer? Should it be CustomerText instead? Custome is local variable and it will be ovewritten in next Get statement.
In the case that the customer cannot be fetched via Get, an additional filter should be set. Maybe then the event should take place after this place:
IF STRLEN(CustomerText) <= MAXSTRLEN(Customer."No.") THEN IF Customer.GET(COPYSTR(CustomerText,1,MAXSTRLEN(Customer."No."))) THEN EXIT(Customer."No.");
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.
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.