---
id: object/codeunit/2675
type: object
title: Codeunit 2675 "Allocation Account Mgt."
summary: Codeunit 2675 "Allocation Account Mgt." in Base Application (Microsoft.Finance.AllocationAccount). 9 public procedures, 4 events. Present since at least BC23, still in BC30, changed in BC24-25, BC27.
tier: official
language: en
tags:
  - codeunit
  - base application
versions:
  introduced: null
  last_changed: "27"
  deprecated: null
review:
  state: derived
  by: null
  at: null
  flags: []
generated:
  at: "2026-10-11T00:31:51.816Z"
  pipeline: 0.2.0
  prompts: {}
  input_hash: ab4e9dc3599e1ac86ac1963f5832b96d86f770673313baf56e6d9169a5d1f8e9
evidence:
  - kind: code
    url: https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/Finance/AllocationAccount/AllocationAccountMgt.Codeunit.al
    title: src/Layers/W1/BaseApp/Finance/AllocationAccount/AllocationAccountMgt.Codeunit.al (releases/29.x)
    date: null
    commit: ea08af5ef2d6a9b5c5af4a029288abbe2c883220
    t: null
    quote: null
links:
  learn: []
  objects: []
  features: []
  topics: []
  localizations: []
  videos: []
  posts: []
  guidelines: []
object_type: codeunit
object_id: 2675
name: Allocation Account Mgt.
namespace: Microsoft.Finance.AllocationAccount
app: Base Application
extends: null
first_version: "23"
last_version: "30"
present_in:
  - "23"
  - "24"
  - "25"
  - "26"
  - "27"
  - "28"
  - "29"
  - "30"
changed_in:
  - "24"
  - "25"
  - "27"
source_major: "29"
obsolete: null
countries: []
ms_search_form_ids: []
counts:
  fields: 0
  procedures: 14
  events: 4
  subscribers: 0
relations:
  out: 0
  referenced_by: 0
  pages: 0
  extended_by: 0
  event_subscribers: 0
  calls: 2
  called_by: 21
  implements: 0
---

# Codeunit 2675 "Allocation Account Mgt."

> Codeunit 2675 "Allocation Account Mgt." in Base Application (Microsoft.Finance.AllocationAccount). 9 public procedures, 4 events. Present since at least BC23, still in BC30, changed in BC24-25, BC27.

Base Application · Microsoft.Finance.AllocationAccount · BC23-30 · [source at ea08af5e](https://github.com/microsoft/BCApps/blob/ea08af5ef2d6a9b5c5af4a029288abbe2c883220/src/Layers/W1/BaseApp/Finance/AllocationAccount/AllocationAccountMgt.Codeunit.al) · facts from BC29

## Events published

- `OnGenerateFixedAllocationLinesOnAfterInsertAllocationLine(var AllocationLine: Record "Allocation Line"; var AllocAccountDistibution: Record "Alloc. Account Distribution")` (integration): Integration event raised after inserting allocation line for fixed allocation methods.
- `OnGenerateVariableAllocationLinesOnAfterInsertAllocationLine(var AllocationLine: Record "Allocation Line"; var AllocAccountDistibution: Record "Alloc. Account Distribution")` (integration): Integration event raised after inserting allocation line for variable allocation methods.
- `OnBeforeGenerateVariableAllocationLines(var AllocationAccount: Record "Allocation Account"; var AllocationLine: Record "Allocation Line"; var ExistingDimensionSetId: Integer)` (integration): Integration event raised before generating variable allocation lines for preprocessing.
- `OnAfterGenerateVariableAllocationLines(var AllocationAccount: Record "Allocation Account"; var AllocationLine: Record "Allocation Line"; var ExistingDimensionSetId: Integer)` (integration): Integration event raised after generating variable allocation lines for postprocessing.

## Procedures

- `UseAllocationAccountNoField(): Boolean`
- `GenerateAllocationLines(var AllocationAccount: Record "Allocation Account"; var AllocationLine: Record "Allocation Line"; AmountToDistribute: Decimal; PostingDate: Date; ExistingDimensionSetId: Integer; CurrencyCode: Code[10])`: Generates allocation lines based on the allocation account configuration and distribution rules.
- `GenerateVariableAllocationLines(var AllocationAccount: Record "Allocation Account"; var AllocationLine: Record "Allocation Line"; AmountToDistribute: Decimal; PostingDate: Date; ExistingDimensionSetId: Integer; CurrencyCode: Code[10])` (internal)
- `GenerateFixedAllocationLines(var AllocationAccount: Record "Allocation Account"; var AllocationLine: Record "Allocation Line"; AmountToDistribute: Decimal; ExistingDimensionSetId: Integer; CurrencyCode: Code[10])` (internal)
- `VerifyNoInheritFromParentUsed(AccountNo: Code[20])`: Validates that allocation account does not use parent inheritance for standalone usage scenarios.
- `GetDefaultAmountForPreview(): Decimal` (internal)
- `GetCurrencyRoundingPrecision(CurrencyCode: Code[10]): Decimal` (internal)
- `GetCurrencyUnitAmountPrecision(CurrencyCode: Code[10]): Decimal` (internal)
- `SplitQuantitiesIfNeeded(OriginalQuantity: Decimal; var AllocationLine: Record "Allocation Line"; var AllocationAccount: Record "Allocation Account")` (internal)

Plus 1 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 408 "DimensionManagement"](../codeunit/408.md) (2 calls: `CombineDimensionSetIds → GetCombinedDimensionSetID`, `CombineDimensionSetIds → UpdateGlobalDimFromDimSetID`)
- [Codeunit 2670 "Variable Allocation Mgt."](../codeunit/2670.md) (1 call: `GenerateVariableAllocationLines → CalculateAmountDistributions`)

## Called by

- [Codeunit 2679 "Purchase Alloc. Acc. Mgt."](../codeunit/2679.md) (4 calls: `GetAmount → GetCurrencyRoundingPrecision`, `GetUnitPrice → GetCurrencyRoundingPrecision`, `MoveAmounts → GetCurrencyRoundingPrecision`, …)
- [Codeunit 2678 "Sales Alloc. Acc. Mgt."](../codeunit/2678.md) (3 calls: `GetAmount → GetCurrencyRoundingPrecision`, `GetUnitPrice → GetCurrencyUnitAmountPrecision`, `VerifySalesLine → VerifyNoInheritFromParentUsed`)
- [Page 2674 "Allocation Account Preview"](../page/2674.md) (3 calls: `OnOpenPage → GetDefaultAmountForPreview`, `UpdateData → GenerateFixedAllocationLines`, `UpdateData → GenerateVariableAllocationLines`)
- [Codeunit 1620 "PEPPOL Validation"](../codeunit/1620.md) (1 call: `CheckAllocationAccountExpandedLines → GenerateAllocationLines`)
- [Codeunit 2670 "Variable Allocation Mgt."](../codeunit/2670.md) (1 call: `CalculateAmountDistributions → GetCurrencyRoundingPrecision`)
- [Codeunit 2677 "Gen. Journal Alloc. Acc. Mgt."](../codeunit/2677.md) (1 call: `VerifyGeneralJournalLine → VerifyNoInheritFromParentUsed`)
- [Page 253 "Sales Journal"](../page/253.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 254 "Purchase Journal"](../page/254.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 255 "Cash Receipt Journal"](../page/255.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 256 "Payment Journal"](../page/256.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 39 "General Journal"](../page/39.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 46 "Sales Order Subform"](../page/46.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 47 "Sales Invoice Subform"](../page/47.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 516 "Sales Lines"](../page/516.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 518 "Purchase Lines"](../page/518.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 54 "Purchase Order Subform"](../page/54.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 55 "Purch. Invoice Subform"](../page/55.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 95 "Sales Quote Subform"](../page/95.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 96 "Sales Cr. Memo Subform"](../page/96.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 97 "Purchase Quote Subform"](../page/97.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)
- [Page 98 "Purch. Cr. Memo Subform"](../page/98.md) (1 call: `OnOpenPage → UseAllocationAccountNoField`)

## Across versions

- Present in: BC23-30
- Changed (declaration) in: BC24-25, BC27

Source: AL metadata extracted from the code (names, ids, signatures, properties); no code bodies (D10).

## 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: "Allocation Account Mgt.")`, then `bcatlas_get_procedure_body` or `bcatlas_get_neighbors` on the returned id.
