Table "Direct Debit Collection Entry"

ID 1208
Namespace: Microsoft.Bank.DirectDebit

Represents individual direct debit transactions within a collection, linking customer ledger entries to specific direct debit mandates and managing the transaction lifecycle from creation to posting.

Properties

Name Value
Caption Direct Debit Collection Entry
DataCaptionFields 3,8
DrillDownPageID Page Microsoft.Bank.DirectDebit."Direct Debit Collect. Entries"
LookupPageID Page Microsoft.Bank.DirectDebit."Direct Debit Collect. Entries"
DataClassification CustomerContent

Fields

Name Type Description
"Direct Debit Collection No." Integer

Reference to the parent direct debit collection that contains this entry.

"Entry No." Integer

Sequential entry number within the direct debit collection.

"Customer No." Code[20]

Customer from whom the direct debit amount will be collected.

"Applies-to Entry No." Integer

Customer ledger entry that this direct debit entry applies to, typically an invoice or reminder.

"Transfer Date" Date

Scheduled date when the direct debit collection will be processed.

"Currency Code" Code[10]

Currency code of the transaction, inherited from the customer ledger entry.

"Transfer Amount" Decimal

Amount to be collected via direct debit from the customer.

"Transaction ID" Text[35]

Unique identifier for the transaction, used in SEPA XML files for tracking purposes.

"Sequence Type" Option

SEPA sequence type indicating whether this is a one-off, first, recurring, or last transaction.

Status Option

Current processing status of the direct debit entry.

"Mandate ID" Code[35]

SEPA direct debit mandate identifier that authorizes this collection.

"Mandate Type of Payment" Option

Payment type specified in the mandate (one-off or recurrent), calculated from the mandate.

"Customer Name" Text[100]

Name of the customer, retrieved from the customer master data.

"Applies-to Entry Document No." Code[20]

Document number of the customer ledger entry this collection applies to.

"Applies-to Entry Description" Text[100]

Description of the customer ledger entry this collection applies to.

"Applies-to Entry Posting Date" Date

Posting date of the customer ledger entry this collection applies to.

"Applies-to Entry Currency Code" Code[10]

Currency code of the customer ledger entry this collection applies to.

"Applies-to Entry Amount" Decimal

Total amount of the customer ledger entry this collection applies to.

"Applies-to Entry Rem. Amount" Decimal

Remaining amount on the customer ledger entry that this collection applies to.

"Applies-to Entry Open" Boolean

Indicates whether the customer ledger entry this collection applies to is still open.

"Direct Debit Collection Status" Option

Status of the parent direct debit collection, retrieved from the collection header.

"Payment Reference" Code[50]

Payment reference from the customer ledger entry, used for reconciliation purposes.

"Message to Recipient" Text[140]

Optional message to be included in the direct debit instruction for the recipient.

SystemId Guid
SystemCreatedAt DateTime
SystemCreatedBy Guid
SystemModifiedAt DateTime
SystemModifiedBy Guid
SystemRowVersion BigInteger

Methods

CreateNew

Creates a new direct debit collection entry based on a customer ledger entry.

procedure CreateNew(DirectDebitCollectionNo: Integer, CustLedgerEntry: Record "Cust. Ledger Entry")

Parameters

Name Type Description
DirectDebitCollectionNo Integer

Collection number to associate this entry with

CustLedgerEntry Table Microsoft.Sales.Receivables."Cust. Ledger Entry"

Customer ledger entry to create the collection for

DeletePaymentFileErrors

Removes payment file errors associated with this collection entry.

procedure DeletePaymentFileErrors()

HasPaymentFileErrors

Checks if any payment file errors exist for this collection entry.

procedure HasPaymentFileErrors(): Boolean

Returns

Type Description
Boolean

True if payment file errors are found

ExportSEPA

Initiates SEPA direct debit export process for this collection entry.

procedure ExportSEPA()

InsertPaymentFileError

Creates a payment file error entry with specified text.

procedure InsertPaymentFileError(Text: Text)

Parameters

Name Type Description
Text Text

Error message text

InsertPaymentFileErrorWithDetails

Creates a payment file error entry with additional details.

procedure InsertPaymentFileErrorWithDetails(ErrorText: Text, AddnlInfo: Text)

Parameters

Name Type Description
ErrorText Text

Primary error message

AddnlInfo Text

Additional information about the error

Reject

Rejects the collection entry and rolls back the mandate sequence type if applicable.

procedure Reject()

GetAmountInActiveCollections

Calculates the total amount already allocated to other active collections for the same customer ledger entry.

procedure GetAmountInActiveCollections(): Decimal

Returns

Type Description
Decimal

Amount already allocated in other collections

SetTodayAsTransferDateForOverdueEnries

Updates transfer dates to today for all overdue entries in the same collection.

procedure SetTodayAsTransferDateForOverdueEnries()

Events

OnBeforeCheckSEPA

Integration event that allows customization of SEPA validation checks.

[IntegrationEvent(False,False)]
local procedure OnBeforeCheckSEPA(var DirectDebitCollectionEntry: Record "Direct Debit Collection Entry", var IsHandled: Boolean)

Parameters

Name Type Description
DirectDebitCollectionEntry Table Microsoft.Bank.DirectDebit."Direct Debit Collection Entry"

The collection entry being validated

IsHandled Boolean

Whether the event has been handled by subscribers

OnBeforeCheckCustLedgerEntryAmountPositive

Integration event that allows customization of customer ledger entry amount validation.

[IntegrationEvent(False,False)]
local procedure OnBeforeCheckCustLedgerEntryAmountPositive(var CustLedgerEntry: Record "Cust. Ledger Entry", var IsHandled: Boolean)

Parameters

Name Type Description
CustLedgerEntry Table Microsoft.Sales.Receivables."Cust. Ledger Entry"

The customer ledger entry being validated

IsHandled Boolean

Whether the event has been handled by subscribers

OnBeforeDocTypeErr

Integration event that allows customization of document type validation logic.

[IntegrationEvent(False,False)]
local procedure OnBeforeDocTypeErr(CustLedgerEntry: Record "Cust. Ledger Entry", var AlllowedDocumentType: Boolean)

Parameters

Name Type Description
CustLedgerEntry Table Microsoft.Sales.Receivables."Cust. Ledger Entry"

The customer ledger entry being validated

AlllowedDocumentType Boolean

Whether the document type is allowed

OnBeforeExportSEPA

Integration event that allows customization of SEPA export processing.

[IntegrationEvent(False,False)]
local procedure OnBeforeExportSEPA(var DirectDebitCollectionEntry: Record "Direct Debit Collection Entry", var IsHandled: Boolean)

Parameters

Name Type Description
DirectDebitCollectionEntry Table Microsoft.Bank.DirectDebit."Direct Debit Collection Entry"

The collection entry being exported

IsHandled Boolean

Whether the event has been handled by subscribers

OnBeforeTransferPKToGenJnlLine

Integration event for customizing primary key transfer to general journal line.

[IntegrationEvent(False,False)]
local procedure OnBeforeTransferPKToGenJnlLine(var DirectDebitCollectionEntry: Record "Direct Debit Collection Entry", var GenJnlLine: Record "Gen. Journal Line", var IsHandled: Boolean)

Parameters

Name Type Description
DirectDebitCollectionEntry Table Microsoft.Bank.DirectDebit."Direct Debit Collection Entry"

The collection entry being processed

GenJnlLine Table Microsoft.Finance.GeneralLedger.Journal."Gen. Journal Line"

The general journal line receiving the primary key

IsHandled Boolean

Whether the event has been handled by subscribers

OnBeforeValidateTransferAmount

Integration event that allows customization of transfer amount validation.

[IntegrationEvent(False,False)]
local procedure OnBeforeValidateTransferAmount(var DirectDebitCollectionEntry: Record "Direct Debit Collection Entry", var IsHandled: Boolean)

Parameters

Name Type Description
DirectDebitCollectionEntry Table Microsoft.Bank.DirectDebit."Direct Debit Collection Entry"

The collection entry being validated

IsHandled Boolean

Whether the event has been handled by subscribers

OnCreateNewOnBeforeInsert

Integration event triggered before inserting a new collection entry.

[IntegrationEvent(False,False)]
local procedure OnCreateNewOnBeforeInsert(CustLedgerEntry: Record "Cust. Ledger Entry", var DirectDebitCollectionEntry: Record "Direct Debit Collection Entry")

Parameters

Name Type Description
CustLedgerEntry Table Microsoft.Sales.Receivables."Cust. Ledger Entry"

The customer ledger entry used to create the collection

DirectDebitCollectionEntry Table Microsoft.Bank.DirectDebit."Direct Debit Collection Entry"

The collection entry being created

OnCreateNewOnAfterInsert

Integration event triggered after inserting a new collection entry.

[IntegrationEvent(False,False)]
local procedure OnCreateNewOnAfterInsert(CustLedgerEntry: Record "Cust. Ledger Entry", var DirectDebitCollectionEntry: Record "Direct Debit Collection Entry")

Parameters

Name Type Description
CustLedgerEntry Table Microsoft.Sales.Receivables."Cust. Ledger Entry"

The customer ledger entry used to create the collection

DirectDebitCollectionEntry Table Microsoft.Bank.DirectDebit."Direct Debit Collection Entry"

The collection entry that was created

OnValidateAppliesToEntryNoOnAfterTransferCustLedgerEntryFields

Integration event triggered after transferring fields from customer ledger entry during validation.

[IntegrationEvent(False,False)]
local procedure OnValidateAppliesToEntryNoOnAfterTransferCustLedgerEntryFields(var DirectDebitCollectionEntry: Record "Direct Debit Collection Entry", xDirectDebitCollectionEntry: Record "Direct Debit Collection Entry", CustLedgerEntry: Record "Cust. Ledger Entry")

Parameters

Name Type Description
DirectDebitCollectionEntry Table Microsoft.Bank.DirectDebit."Direct Debit Collection Entry"

The collection entry being validated

xDirectDebitCollectionEntry Table Microsoft.Bank.DirectDebit."Direct Debit Collection Entry"

The previous state of the collection entry

CustLedgerEntry Table Microsoft.Sales.Receivables."Cust. Ledger Entry"

The customer ledger entry being applied

See also