codeunitFinanceofficial - Microsoftderived - from the source, no model text

Codeunit 230 "GenJnlManagement"

Base Application · Microsoft.Finance.GeneralLedger.Journal

Across versions

  1. BC23-28present
  2. BC292 procedures added
  3. BC30unchanged

Neighbourhood 25 connected objects and pages

Codeunit 1695 "Bank Deposit Subscribers" (event subscribers)Bank Deposit SubscribersPage 39 "General Journal" (calls, 11 links)General JournalPage 254 "Purchase Journal" (calls, 9 links)Purchase JournalPage 253 "Sales Journal" (calls, 8 links)Page 256 "Payment Journal" (calls, 7 links)Payment JournalPage 255 "Cash Receipt Journal" (calls, 6 links)Cash Receipt JournalPage 1020 "Job G/L Journal" (calls, 5 links)Job G/L JournalPage 283 "Recurring General Journal" (calls, 5 links)Recurring General JournalPage 5628 "Fixed Asset G/L Journal" (calls, 5 links)Page 610 "IC General Journal" (calls, 5 links)IC General JournalPage 1190 "Create Payment" (calls, 2 links)Create PaymentPage 1690 "Bank Deposit" (calls, 2 links)Bank DepositTable 1690 "Bank Deposit Header" (calls, 2 links)Bank Deposit HeaderCodeunit 181 "Copy Gen. Journal Mgt." (calls)Copy Gen. Journal Mgt.Codeunit 233 "Gen. Jnl.-B.Post" (calls)Gen. Jnl.-B.PostCodeunit 234 "Gen. Jnl.-B.Post+Print" (calls)Codeunit 5469 "Library API - General Journal" (calls)Library API - General JournalPage 251 "General Journal Batches" (calls)Page 9120 "Journal Line Details FactBox" (calls)Report 1497 "Trans. Bank Rec. to Gen. Jnl." (calls)Report 597 "G/L Currency Revaluation" (calls)Report 8610 "Create G/L Acc. Journal Lines" (calls)Report 8611 "Create Customer Journal Lines" (calls)Report 8612 "Create Vendor Journal Lines" (calls)Table 750 "Standard General Journal" (calls)

Open in the neighbourhood explorer

One hop out, from the extracted relations and call graph. Up to 40 shown; the sections below list them all.

Base Application · Microsoft.Finance.GeneralLedger.Journal · BC23-30 · source at ea08af5e · facts from BC29

Properties

Property Value
Permissions TableData “Gen. Journal Template” = rimd, TableData “Gen. Journal Batch” = rimd

Events published

  • OnAfterGetAccounts(var GenJournalLine: Record "Gen. Journal Line"; var AccName: Text[100]; var BalAccName: Text[100]) (integration): Integration event raised after retrieving account names for journal line display. Enables customization of account name lookup and display logic.
  • OnAfterCheckName(GenJnlBatch: Record "Gen. Journal Batch"; CurrentJnlBatchName: Code[10]; var GenJournalLine: Record "Gen. Journal Line") (integration): Integration event raised after validating journal batch name exists and is properly configured. Enables custom batch validation logic and post-validation processing.
  • OnAfterSetName(var GenJournalLine: Record "Gen. Journal Line"; CurrentJnlBatchName: Code[10]) (integration): Integration event raised after setting journal batch filter on journal lines. Enables custom filtering logic and post-filter processing.
  • OnAfterOpenJournalBatch(GenJnlBatch: Record "Gen. Journal Batch"; GenJnlTemplate: Record "Gen. Journal Template") (integration): Integration event raised after opening journal batch operations complete. Enables custom logic after batch and template have been selected and configured.
  • OnAfterTemplateSelection(var GenJnlTemplate: Record "Gen. Journal Template"; var GenJnlLine: Record "Gen. Journal Line"; var JnlSelected: Boolean; var OpenFromBatch: Boolean; RecurringJnl: Boolean) (integration): Integration event raised after template selection process completes. Enables custom logic after template selection and journal page launch.
  • OnBeforeLookupName(var GenJnlBatch: Record "Gen. Journal Batch"; var GenJnlLine: Record "Gen. Journal Line") (integration): Integration event raised before journal batch name lookup operations. Enables custom filtering or validation logic before batch selection.
  • OnBeforeGetJournalSimplePageModePreference(PageIdToCheck: Integer) (integration): Integration event raised before retrieving journal simple page mode preference. Enables custom logic before preference retrieval.
  • OnBeforeSetJournalSimplePageModePreference(var SetToSimpleMode: Boolean; PageIdToSet: Integer; var IsHandled: Boolean) (integration): Integration event raised before setting journal simple page mode preference. Enables custom validation or modification of preference settings.
  • OnBeforeOpenJnl(var CurrentJnlBatchName: Code[10]; var GenJnlLine: Record "Gen. Journal Line") (integration): Integration event raised before opening journal with batch name operations. Enables custom validation or preprocessing before journal opening.
  • OnBeforeOpenJnlBatch(var GenJnlBatch: Record "Gen. Journal Batch"; var IsHandled: Boolean) (integration): Integration event raised before journal batch opening operations. Enables custom logic to completely override batch opening process.
  • OnBeforeOpenJournalPageFromBatch(var GenJnlBatch: Record "Gen. Journal Batch"; var GenJnlTemplate: Record "Gen. Journal Template"; var IsHandled: Boolean) (integration): Integration event raised before opening journal page from batch context. Enables custom logic to override page opening from batch selection.
  • OnBeforeRunTemplateJournalPage(var GenJnlTemplate: Record "Gen. Journal Template"; var GenJnlLine: Record "Gen. Journal Line"; OpenFromBatch: Boolean; var IsHandled: Boolean) (integration): Integration event raised before running template journal page operations. Enables custom logic to override journal page launching.
  • OnTemplateSelectionSetFilter(var GenJnlTemplate: Record "Gen. Journal Template"; var PageTemplate: Option; var RecurringJnl: Boolean; PageId: Integer; var GenJnlLine: Record "Gen. Journal Line") (integration): Integration event raised during template selection to enable custom filtering logic. Allows modification of template filters and selection criteria.
  • OnFindTemplateFromSelectionOnBeforeGenJnlTemplateInsert(var GenJnlTemplate: Record "Gen. Journal Template") (integration): Integration event raised before inserting a new journal template during template selection. Enables custom template configuration before insertion.
  • OnOpenJnlOnAfterCheckTemplateName(var GenJournalLine: Record "Gen. Journal Line"; var CurrentJnlBatchName: Code[10]) (integration): Integration event raised after template name checking during journal opening. Enables custom processing after template validation.
  • OnOpenJnlBatchOnBeforeCheckGenJnlTemplateCount(var GenJnlBatch: Record "Gen. Journal Batch"; var GenJnlTemplate: Record "Gen. Journal Template") (integration): Integration event raised before checking journal template count during batch operations. Enables custom template filtering or validation logic.
  • OnAfterCalcBalance(var GenJournalLine: Record "Gen. Journal Line") (integration): Integration event raised after balance calculation operations complete. Enables custom processing or validation after balance calculations.
  • OnCalcBalanceOnAfterCopyFilters(var TempGenJournalLine: Record "Gen. Journal Line" temporary) (integration): Integration event raised after copying filters during balance calculation setup. Enables custom filter modification before balance calculation processing.
  • OnCalcBalanceOnBeforeTempGenJnlLineNext(var TempGenJournalLine: Record "Gen. Journal Line") (integration): Integration event raised before moving to next record during balance calculation. Enables custom record positioning logic during balance calculation.

Procedures

  • TemplateSelection(PageID: Integer; PageTemplate: Enum "Gen. Journal Template Type"; RecurringJnl: Boolean; var GenJnlLine: Record "Gen. Journal Line"; var JnlSelected: Boolean): Manages template selection for journal pages based on page type and recurring journal requirements. Filters available templates and launches appropriate journal interface.
  • TemplateSelectionFromBatch(var GenJnlBatch: Record "Gen. Journal Batch"): Opens journal interface directly from a batch selection, bypassing template selection. Validates batch configuration and launches the appropriate journal page.
  • OpenJnl(var CurrentJnlBatchName: Code[10]; var GenJnlLine: Record "Gen. Journal Line"): Opens journal batch with current batch name and manages batch selection logic. Handles batch validation and provides default batch creation when necessary.
  • OpenJnlBatch(var GenJnlBatch: Record "Gen. Journal Batch"): Opens and initializes a general journal batch with template selection and validation. Ensures proper batch setup by creating missing templates and handling batch selection logic.
  • IsBatchNoSeriesEmpty(var CurrentJnlBatchName: Code[10]; var GenJnlLine: Record "Gen. Journal Line"): Boolean: Checks if the journal batch has an empty number series configuration. Validates whether the batch requires manual document numbering or has automatic numbering configured.
  • CheckTemplateName(CurrentJnlTemplateName: Code[10]; var CurrentJnlBatchName: Code[10])
  • CheckName(CurrentJnlBatchName: Code[10]; var GenJnlLine: Record "Gen. Journal Line"): Validates journal batch exists and gets batch configuration for the specified batch name. Ensures batch is properly configured before allowing journal operations.
  • CheckCurrencyCode(CurrencyCode: Code[10]): Validates currency code exists in the currency master data. Provides currency validation for journal line processing.
  • SetName(CurrentJnlBatchName: Code[10]; var GenJnlLine: Record "Gen. Journal Line"): Sets journal batch filter on journal lines and positions to first record. Configures journal line record for batch-specific operations.
  • SetJournalSimplePageModePreference(SetToSimpleMode: Boolean; PageIdToSet: Integer): Configures journal page display mode preference for the current user. Stores user preference for simple or classic view mode in journal pages.
  • GetJournalSimplePageModePreference(PageIdToCheck: Integer): Boolean: Retrieves journal page display mode preference for the current user. Returns user preference for simple or classic view mode in journal pages.
  • GetLastViewedJournalBatchName(PageIdToCheck: Integer): Code[10]: Retrieves the last viewed journal batch name for a specific page from user preferences. Returns stored user preference for batch selection when reopening journal pages.
  • SetLastViewedJournalBatchName(PageIdToCheck: Integer; GenJnlBatch: Code[10]): Stores the last viewed journal batch name for a specific page in user preferences. Updates user preference for batch selection to improve user experience on page reopening.
  • LookupName(var CurrentJnlBatchName: Code[10]; var GenJnlLine: Record "Gen. Journal Line"): Provides journal batch lookup functionality with filtering and selection capabilities. Opens batch selection page and updates current batch name based on user selection.
  • SetJnlBatchName(var GenJnlLine: Record "Gen. Journal Line"): Opens journal batch name lookup and updates journal line batch assignment. Provides user interface for selecting and assigning journal batch to current line.
  • GetAccounts(var GenJnlLine: Record "Gen. Journal Line"; var AccName: Text[100]; var BalAccName: Text[100]): Retrieves and caches account names for display in journal lines to improve user experience. Optimizes performance by caching account names to avoid repeated database lookups.
  • CalcBalance(var GenJnlLine: Record "Gen. Journal Line"; LastGenJnlLine: Record "Gen. Journal Line"; var Balance: Decimal; var TotalBalance: Decimal; var ShowBalance: Boolean; var ShowTotalBalance: Boolean): Calculates running balance and total balance for journal lines within the current batch context. Provides balance calculations for journal line display and validation purposes.
  • CalcBatchTotal(var GenJnlLine: Record "Gen. Journal Line"; var BatchTotal: Decimal; var ShowBatchTotal: Boolean) + BC29
  • GetAvailableGeneralJournalTemplateName(TemplateName: Code[10]): Code[10]: Generates unique journal template names by checking for conflicts and incrementing names when needed. Ensures new template names are unique while maintaining meaningful naming based on template type.
  • TemplateSelectionSimple(var GenJnlTemplate: Record "Gen. Journal Template"; TemplateType: Enum "Gen. Journal Template Type"; RecurringJnl: Boolean): Boolean
  • ShowNotificationIfSpendRequestIsRequired(GLAccountNo: Code[20]; SpendRequestNo: Code[20]; var NotificationID: Guid) + BC29 (internal): Used from journal pages and warns users of need to specify spend request no.

Plus 5 local procedures.

Triggers

OnRun

Called by

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.

Recent changes

Countries that replace it

NL

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: "GenJnlManagement"), then bcatlas_get_procedure_body or bcatlas_get_neighbors on the returned id.

Evidence 1 sources