Table of Contents

OnBeforeSetPostedAmount Event

Codeunit Contract Posting Mgt.

Raised before posted amounts are set in contract entries. Posted amount is fetched from line amount in the posted document line while the sales document is posted.

Signature

[IntegrationEvent(false, false)]
OnBeforeSetPostedAmount(Type: Enum "Sales Document Type"; DocumentNo: Code[20]; var ContractEntry: Record "QWEPR Contract Entry"; var LineAmount: Decimal; var LineDiscountPercent: Decimal; var IsHandled: Boolean)

Parameters

Type Enum "Sales Document Type"

Type of sales document (Invoice or Credit Memo).

DocumentNo Code[20]

Document No. of the posted sales document.

var ContractEntry Record "QWEPR Contract Entry"

The contract entry connected to the document line being posted.

var LineAmount Decimal

Line Amount from the posted document line. LineAmount will be used to set Posted Amount and calculate Posted Amount (LCY) in ContractEntry

var LineDiscountPercent Decimal

Line Discount % from the posted document line. LineDiscountPercent will be used to set Posted Line Discount % in ContractEntry

var IsHandled Boolean

Should be set to true to skip standard functionality for how posted amounts in contract entries are set. Should be honored if already set. (Handled Pattern)

This documentation is generated from Parrot v27.0