profile
viewpoint

Ask questions[Event Request] Codeunit 5702 "Dist. Integration" - OnBeforeInitItemCrossReferenceFilters

Hi, would it be possible to get an event OnBeforeInitItemCrossReferenceFilters in codeunit 5702 (Dist. Integration), like this:

local procedure InitItemCrossReferenceFilters(var ItemCrossReference: Record "Item Cross Reference"; ItemNo: Code[20]; CrossRefNo: Code[20]; CrossRefType: Integer)
    var
         IsHandled: Boolean;
    begin
        IsHandled := false;
        OnBeforeInitItemCrossReferenceFilters(ItemCrossReference,ItemNo,CrossRefNo,CrossRefType,IsHandled);
        if IsHandled then
            exit;
        with ItemCrossReference do begin
            Reset;
            SetCurrentKey(
              "Cross-Reference No.", "Cross-Reference Type", "Cross-Reference Type No.", "Discontinue Bar Code");
            SetRange("Cross-Reference No.", CrossRefNo);
            SetRange("Item No.", ItemNo);
            SetFilter("Cross-Reference Type", '<>%1', GetCrossReferenceTypeToExclude(CrossRefType));
            SetRange("Discontinue Bar Code", false);
            if IsEmpty then
                SetRange("Item No.");
        end;
    end;
[IntegrationEvent(false, false)]
local procedure OnBeforeInitItemCrossReferenceFilters(var ItemCrossReference: Record "Item Cross Reference"; ItemNo: Code[20]; CrossRefNo: Code[20]; CrossRefType: Integer; var IsHandled: Boolean)
begin
end;

Thanks

microsoft/ALAppExtensions

Answer questions AlexanderYakunin

All related to Item Cross Reference table will be removed.

useful!
source:https://uonfu.com/
answerer
Alexander Yakunin AlexanderYakunin Microsoft Principal Software Engineering Manager, Dynamics NAV
Github User Rank List