IF (ToSalesLine.“No.” <> Rec.“No.”) AND (STRPOS(ToSalesLine.“Description 2”, ‘orado’) > 0) THEN
ToSalesLine.VALIDATE(“Line Discount %”, 100);
IF (ToSalesLine.“No.” <> Rec.“No.”) AND (STRPOS(ToSalesLine.“Description 2”, ‘efit’) > 0) THEN
ToSalesLine.VALIDATE(“Line Discount %”, 100);
So if this lies between 1-10-2016 and 31-03-2017 then execute the lines.
Hi,
For Reference Look into codeunit 11 Function DateNotAllowed. This checks the dates for every posting based on user setup and general ledger setup.
You can create a function like this.
IF StartDateNefit = TODAY THEN BEGIN
IF (ToSalesLine.“No.” <> Rec.“No.”) AND (STRPOS(ToSalesLine.“Description 2”, ‘efit’) > 0) THEN
ToSalesLine.VALIDATE(“Line Discount %”, 100);
END;
But I still dont have the between(setrange). I only have begin date