Use this event to
Add filter conditions for Item Ledger Entry that cannot be solved by OnSetFilter- event (Location Not using Bins).
Description
This event affects locations with Location."Bin Mandatory" = false.
The entries can be excluded from the response by setting the parameter _IncludeInLookup to false.
Template
[EventSubscriber(ObjectType::Codeunit, Codeunit::"MOB WMS History", 'OnLookupOnHistory_OnIncludeItemLedgerEntry', '', true, true)]
local procedure OnLookupOnHistory_OnIncludeItemLedgerEntry(_ItemLedgerEntry: Record "Item Ledger Entry"; var _IncludeInLookup: Boolean)
begin
end;
Example
// [Example]: Exclude from response if Quantity is more than 1.
[EventSubscriber(ObjectType::Codeunit, Codeunit::"MOB WMS History", 'OnLookupOnHistory_OnIncludeItemLedgerEntry', '', true, true)]
local procedure MyOnLookupOnHistory_OnIncludeItemLedgerEntry(_ItemLedgerEntry: Record "Item Ledger Entry"; var _IncludeInLookup: Boolean)
begin
if _ItemLedgerEntry.Quantity > 1 then
_IncludeInLookup := false;
end;
More examples
-
Case: Filter Receipts based on Comments — The user wants to filter Receipts on whether they have comments or not
-
How-to: Filter Order Lines — Examples of filtering Order Lines .
-
How-to: Filter Orders - Complex — Examples for including/excluding orders using complex per-document filtering
Version History
Version | Changes |
---|---|
MOB5.45 | Introduced |