Codeunit 6201 "Non-Ded. VAT Impl."
Base Application · Microsoft.Finance.VAT.Calculation
Across versions
- BC23-24present
- BC253 procedures added
- BC2611 procedures removed, 1 procedures added
- BC271 procedures added
- BC28-30unchanged
Neighbourhood 1 connected objects and pages
Base Application · Microsoft.Finance.VAT.Calculation · BC23-30 · source at ea08af5e · facts from BC29
Properties
| Property | Value |
|---|---|
| Access | Internal |
| Permissions | tabledata “VAT Setup” = r |
Event subscriptions
- CreateVATSetupOnCompanyInitialize subscribes to Codeunit “Company-Initialize” OnCompanyInitialize
Procedures
IsNonDeductibleVATEnabled(): BooleanShowNonDeductibleVATInLines(): BooleanOpenVATPostingSetupPage(Notification: Notification)GetNonDeductibleVATAmount(GenJournalLine: Record "Gen. Journal Line"): DecimalGetNonDeductibleVATAmount(PurchaseLine: Record "Purchase Line"): DecimalGetNonDeductibleVATPct(VATBusPostGroupCode: Code[20]; VATProdPostGroupCode: Code[20]; GeneralPostingType: Enum "General Posting Type"): DecimalGetNonDeductibleVATPct(VATPostingSetup: Record "VAT Posting Setup"; GeneralPostingType: Enum "General Posting Type"): DecimalGetNonDeductibleVATPct(VATBusPostGroupCode: Code[20]; VATProdPostGroupCode: Code[20]; DeferralDocType: Enum "Deferral Document Type"): DecimalGetNonDeductibleVATAccForDeferrals(DeferralDocType: Enum "Deferral Document Type"; PostingGLAccountNo: Code[20]; VATPostingSetup: Record "VAT Posting Setup"): Code[20]SetNonDeductiblePct(var PurchaseLine: Record "Purchase Line")Init(var NonDedVATBase: Decimal; var NonDedVATAmount: Decimal; var NonDedVATBaseACY: Decimal; var NonDedVATAmountACY: Decimal; var NonDedVATDiff: Decimal; PurchaseLine: Record "Purchase Line"; PurchaseLineACY: Record "Purchase Line")InitNonDeductibleVATDiff(var PurchaseLine: Record "Purchase Line")Update(var PurchaseLine: Record "Purchase Line"; var TempVATAmountLineRemainder: Record "VAT Amount Line" temporary; Currency: Record Currency)− BC26 − BC26Update(var PurchaseLine: Record "Purchase Line"; Currency: Record Currency)− BC26 − BC26Update(var PurchaseLine: Record "Purchase Line"; Part: Decimal; Total: Decimal; AmountRoundingPrecision: Decimal)− BC26 − BC26DivideNonDeductibleVATInPurchaseLine(var PurchaseLine: Record "Purchase Line"; var VATAmountLineRemainder: Record "VAT Amount Line"; VATAmountLine: Record "VAT Amount Line"; Currency: Record Currency; Part: Decimal; Total: Decimal)ValidateVATAmountInVATAmountLine(var VATAmountLine: Record "VAT Amount Line")ValidateNonDeductibleVATInVATAmountLine(var VATAmountLine: Record "VAT Amount Line")Update(var VATAmountLine: Record "VAT Amount Line"; Currency: Record Currency)− BC26 − BC26UpdateNonDeductibleAmountsWithDiffInVATAmountLine(var VATAmountLine: Record "VAT Amount Line"; Currency: Record Currency)SetNonDedVATAmountInPurchLine(var PurchaseLine: Record "Purchase Line"; NonDeductibleVATAmount: Decimal)SetNonDedVATAmountDiffInPurchLine(var PurchaseLine: Record "Purchase Line"; var VATAmountLineRemainder: Record "VAT Amount Line"; var VATDifference: Decimal; VATAmountLine: Record "VAT Amount Line"; Currency: Record Currency; Part: Decimal; Total: Decimal)SetNonDeductibleVATAmount(var VATEntry: Record "VAT Entry"; NonDedVATAmount: Decimal; NonDedVATAmountACY: Decimal)SetNonDeductibleVATBase(var VATEntry: Record "VAT Entry"; NonDedVATBase: Decimal; NonDedVATBaseACY: Decimal)GetNonDedVATAmountFromVATAmountLine(var VATAmountLineRemainder: Record "VAT Amount Line"; VATAmountLine: Record "VAT Amount Line"; Currency: Record Currency; Part: Decimal; Total: Decimal): DecimalAddNonDedAmountsOfPurchLineToVATAmountLine(var VATAmountLine: Record "VAT Amount Line"; var VATAmountLineRemainder: Record "VAT Amount Line"; PurchaseLine: Record "Purchase Line"; Currency: Record Currency; Part: Decimal; Total: Decimal)CopyNonDedVATFromPurchInvLineToVATAmountLine(var VATAmountLine: Record "VAT Amount Line"; PurchInvLine: Record "Purch. Inv. Line")CopyNonDedVATFromPurchCrMemoLineToVATAmountLine(var VATAmountLine: Record "VAT Amount Line"; PurchCrMemoLine: Record "Purch. Cr. Memo Line")CopyNonDedVATAmountFromGenJnlLineToGLEntry(var GLEntry: Record "G/L Entry"; GenJournalLine: Record "Gen. Journal Line")CopyNonDedVATFromGenJnlLineToFALedgEntry(var FALedgEntry: Record "FA Ledger Entry"; GenJnlLine: Record "Gen. Journal Line")+ BC25CopyNonDedVATFromGenJnlLineToJobJnlLine(var JobJnlLine: Record "Job Journal Line"; GenJnlLine: Record "Gen. Journal Line")+ BC26CheckPrepmtWithNonDeductubleVATInPurchaseLine(PurchaseLine: Record "Purchase Line")CheckPrepmtVATPostingSetup(VATPostingSetup: Record "VAT Posting Setup")CheckUnrealizedVATWithNonDeductibleVATInVATPostingSetup(VATPostingSetup: Record "VAT Posting Setup")CheckVATPostingSetupChangeIsAllowed(VATPostingSetup: Record "VAT Posting Setup")CheckNonDeductibleVATPctIsAllowed(PurchaseLine: Record "Purchase Line")CheckNonDeductibleVATAmountDiff(var TempVATAmountLine: Record "VAT Amount Line" temporary; xTempVATAmountLine: Record "VAT Amount Line" temporary; AllowVATDifference: Boolean; Currency: Record Currency)Increment(var TotalVATAmountLine: Record "VAT Amount Line"; VATAmountLine: Record "VAT Amount Line")− BC26DeductNonDedValuesFromVATAmountLine(var TotalVATAmountLine: Record "VAT Amount Line"; VATAmountLineDeduct: Record "VAT Amount Line")Reverse(var PurchaseLine: Record "Purchase Line")− BC26Reverse(var InvoicePostingBuffer: Record "Invoice Posting Buffer")− BC26Reverse(var GLEntry: Record "G/L Entry"; GLEntryToReverse: Record "G/L Entry")− BC26Reverse(var VATEntry: Record "VAT Entry")− BC26Increment(var TotalPurchaseLine: Record "Purchase Line"; PurchaseLine: Record "Purchase Line")− BC26Increment(var TotalInvoicePostingBuffer: Record "Invoice Posting Buffer"; InvoicePostingBuffer: Record "Invoice Posting Buffer")− BC26IsNonDedFALedgEntryInFirstAcquisition(FALedgEntry: Record "FA Ledger Entry"): Boolean+ BC25Update(var TotalNonDedVATBase: Decimal; var TotalNonDedVATAmount: Decimal; var TotalNonDedVATBaseACY: Decimal; var TotalNonDedVATAmountACY: Decimal; var TotalNonDedVATDiff: Decimal; InvoicePostingBuffer: Record "Invoice Posting Buffer")− BC26 − BC26SetNonDeductibleVAT(var InvoicePostingBuffer: Record "Invoice Posting Buffer"; TotalNonDedVATBase: Decimal; TotalNonDedVATAmount: Decimal; TotalNonDedVATBaseACY: Decimal; TotalNonDedVATAmountACY: Decimal; TotalNonDedVATDiff: Decimal)− BC26RoundNonDeductibleVAT(PurchaseHeader: Record "Purchase Header"; var PurchaseLine: Record "Purchase Line"; TotalPurchaseLine: Record "Purchase Line"; TotalPurchaseLineLCY: Record "Purchase Line")ClearNonDeductibleVAT(var PurchaseLine: Record "Purchase Line")− BC26ClearNonDeductibleVAT(var InvoicePostingBuffer: Record "Invoice Posting Buffer")− BC26Update(var InvoicePostingBuffer: Record "Invoice Posting Buffer"; var ReminderInvoicePostingBuffer: Record "Invoice Posting Buffer"; AmountRoundingPrecision: Decimal)− BC26 − BC26ValidateNonDedVATPctInGenJnlLine(var GenJournalLine: Record "Gen. Journal Line")ValidateBalNonDedVATPctInGenJnlLine(var GenJournalLine: Record "Gen. Journal Line")Calculate(var GenJournalLine: Record "Gen. Journal Line"; Currency: Record Currency)− BC26CalculateBalAcc(var GenJournalLine: Record "Gen. Journal Line"; Currency: Record Currency)Calculate(var InvoicePostingBuffer: Record "Invoice Posting Buffer")− BC26Calculate(var NonDeductibleBaseAmount: Decimal; var NonDeductibleVATAmount: Decimal; var NonDeductibleVATAmtPerUnit: Decimal; var NonDeductibleVATAmtPerUnitLCY: Decimal; var NDVATAmountRounding: Decimal; var NDVATBaseRounding: Decimal; PurchaseHeader: Record "Purchase Header"; PurchaseLine: Record "Purchase Line")− BC26Copy(var InvoicePostingBuffer: Record "Invoice Posting Buffer"; PurchaseLine: Record "Purchase Line")− BC26 − BC26Copy(var VATEntry: Record "VAT Entry"; GenJournalLine: Record "Gen. Journal Line")− BC26 − BC26SetNonDedVATInVATEntry(var VATEntry: Record "VAT Entry"; NonDedBase: Decimal; NonDedVATAmount: Decimal; SrcCurrNonDedBaseAmount: Decimal; SrcCurrNonDedVATAmount: Decimal; NonDedVATDiff: Decimal; NonDedVATDiffACY: Decimal)ClearNonDedVATACYInVATEntry(var VATEntry: Record "VAT Entry")Copy(var GenJournalLine: Record "Gen. Journal Line"; InvoicePostingBuffer: Record "Invoice Posting Buffer")− BC26 − BC26ExchangeAccGLJournalLine(var GenJournalLine: Record "Gen. Journal Line"; CopiedGenJournalLine: Record "Gen. Journal Line")AdjustVATAmountsFromGenJnlLine(var VATAmount: Decimal; var BaseAmount: Decimal; var VATAmountACY: Decimal; var BaseAmountACY: Decimal; var GenJournalLine: Record "Gen. Journal Line")GetNonDeductibleAmount(Amount: Decimal; NonDeductiblePercent: Decimal; AmountRoundingPrecision: Decimal; var Rounding: Decimal): DecimalGetNonDeductibleVATBaseBothCurrencies(var NonDedVATBase: Decimal; var NonDedVATBaseACY: Decimal; VATEntry: Record "VAT Entry")AdjustRoundingForInvoicePostingBufferUpdate(var RoundingInvoicePostingBuffer: Record "Invoice Posting Buffer"; var CurrInvoicePostingBuffer: Record "Invoice Posting Buffer")GetNonDeductibleVATAmountForItemCost(PurchaseLine: Record "Purchase Line"): DecimalUseNonDeductibleVATAmountForFixedAssetCost(): BooleanUseNonDeductibleVATAmountForJobCost(): BooleanApplyRoundingForFinalPostingFromInvoicePostingBuffer(var RoundingInvoicePostingBuffer: Record "Invoice Posting Buffer"; var CurrInvoicePostingBuffer: Record "Invoice Posting Buffer")
Plus 15 local procedures.
Calls
From the extracted call graph of BC29 (graphify-al on the snapshot checkout): calls whose target is known from a declared type or an Object::"Name" argument. Interface dispatch and calls through events are not counted, so the list is not complete.
- Codeunit 6200 “Non-Deductible VAT” (18 calls:
AddNonDedAmountsOfPurchLineToVATAmountLine → OnBeforeAddNonDedAmountsOfPurchLineToVATAmountLine,AdjustVATAmountsFromGenJnlLine → OnBeforeAdjustVATAmountsFromGenJnlLine,CalcRevChargeVATAmountInPurchLine → OnAfterCalcRevChargeVATAmountInPurchLine, …)
Called by
- Codeunit 6200 “Non-Deductible VAT” (53 calls:
AddNonDedAmountsOfPurchLineToVATAmountLine → AddNonDedAmountsOfPurchLineToVATAmountLine,AdjustRoundingForInvoicePostingBufferUpdate → AdjustRoundingForInvoicePostingBufferUpdate,AdjustVATAmountsFromGenJnlLine → AdjustVATAmountsFromGenJnlLine, …)
Recent changes
- 2026-10-05 #12141 [Master]-Incorrect project ledger costs when non-deductible VAT is posted to a foreign-currency project (main, BC30, fix)
- 2026-09-10 #10880 [29.X]-Inconsistent Validation of Non-Deductible VAT % for Purchase Lines Sharing the Same VAT Identifier (releases/29.x, BC29, fix)
- 2026-09-01 #10609 [Master]-Inconsistent Validation of Non-Deductible VAT % for Purchase Lines Sharing the Same VAT Identifier- #10607 (main, BC30, fix)
Ask your agent
Procedure bodies are not stored here (D10). The call sections above are our own, per object, from the BC29 call graph. For a procedure body or the calls of one procedure, ask bc-code-atlas (external, by Stefan Maron, MIT; default corpus w1-28), which the bc-observatory plugin connects: bcatlas_resolve_node(object_type: "codeunit", object_name: "Non-Ded. VAT Impl."), then bcatlas_get_procedure_body or bcatlas_get_neighbors on the returned id.