Codeunit 100 "Calc. G/L Acc. Where-Used"
Base Application · Microsoft.Finance.GeneralLedger.Account
Across versions
- BC23-30present
Neighbourhood 12 connected objects and pages
Base Application · Microsoft.Finance.GeneralLedger.Account · BC23-30 · source at ea08af5e · facts from BC29
Events published
OnShowExtensionPage(GLAccountWhereUsed: Record "G/L Account Where-Used")(integration): Integration event raised to allow extensions to handle custom setup page navigation. Enables custom object types to be included in the where-used analysis with specialized page handling.- subscribers: Codeunit 18 “Financial Report Mgt.” OnShowExtensionPage, Codeunit 5958 “Serv. Calc. G/L Acc.Where-Used” OnShowExtensionPage, Codeunit 6789 “Withholding Tax Event Handler” OnShowExtensionPage
OnAfterCheckPostingGroups(var TempGLAccountWhereUsed: Record "G/L Account Where-Used" temporary; GLAccNo: Code[20])(integration): Integration event raised after completing posting group analysis for a G/L account. Allows extensions to add custom table checks or modify the where-used results before display.- subscribers: Codeunit 18 “Financial Report Mgt.” OnAfterCheckPostingGroups
OnAfterFillTableBuffer(var TableBuffer: Record "Integer")(integration): Integration event raised after building the list of tables to check for G/L account usage. Enables extensions to add custom tables to the where-used analysis scope.- subscribers: Codeunit 5958 “Serv. Calc. G/L Acc.Where-Used” OnAfterFillTableBuffer, Codeunit 6789 “Withholding Tax Event Handler” OnAfterFillTableBuffer
OnBeforeShowGLAccWhereUsed(var GLAccountWhereUsed: Record "G/L Account Where-Used")(integration): Integration event raised before displaying the where-used list to the user. Allows extensions to filter or modify the results before presentation.OnShowSetupFormOnBeforeFAAllocationRunPage(var FAAllocation: Record "FA Allocation"; var GLAccountWhereUsed: Record "G/L Account Where-Used")(integration): Integration event raised before opening the FA Allocation page from where-used navigation. Enables extensions to customize FA allocation page behavior or apply additional filters.OnDeleteGLNoOnBeforeTempGLAccWhereUsedFindFirst(var TempGLAccountWhereUsed: Record "G/L Account Where-Used" temporary)(integration): Integration event raised before checking if where-used entries exist during G/L account deletion validation. Allows extensions to perform custom where-used checks or modify validation logic.
Procedures
ShowSetupForm(GLAccWhereUsed: Record "G/L Account Where-Used"): Opens the appropriate setup form for the table referenced in the where-used entry. Navigates directly to the configuration page where the G/L account is being used.DeleteGLNo(GLAccNo: Code[20]): Boolean: Validates if a G/L account can be deleted by checking for usage in setup tables. Displays where-used information if account is referenced, preventing deletion.CheckGLAcc(GLAccNo: Code[20]): Analyzes where a G/L account is used and displays the results in the where-used list. Provides comprehensive analysis of account dependencies across all setup tables.InsertGroupForRecord(var TempGLAccountWhereUsed: Record "G/L Account Where-Used" temporary; TableID: Integer; TableCaption: Text[80]; GLAccNo: Code[20]; GLAccNo2: Code[20]; FieldCaption: Text[80]; Key: array[8] of Text[80]): Inserts a where-used entry group for a specific record using table metadata. Creates standardized entries for account usage tracking with table and field information.CheckPostingGroups(GLAccNo: Code[20]): Performs comprehensive analysis of posting group tables to identify where a G/L account is used. Scans all relevant setup tables using metadata relationships to build complete usage report.AddTable(var TableBuffer: Record "Integer"; TableID: Integer): Adds a table to the buffer of tables to be checked for G/L account usage. Prevents duplicate entries when building the list of tables to analyze.
Plus 8 local procedures.
Triggers
OnRun
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 27 “Confirm Management” (1 call:
DeleteGLNo → GetResponse) - Page 101 “General Journal Templates” (1 call:
ShowSetupForm → (object)) - Page 284 “Allocations” (1 call:
ShowSetupForm → (object)) - Page 459 “Sales & Receivables Setup” (1 call:
ShowSetupForm → (object)) - Page 460 “Purchases & Payables Setup” (1 call:
ShowSetupForm → (object)) - Page 5612 “FA Posting Group Card” (1 call:
ShowSetupForm → (object)) - Page 5826 “Inventory Posting Setup” (1 call:
ShowSetupForm → (object))
Called by
- Codeunit 361 “MoveEntries” (1 call:
MoveGLEntries → DeleteGLNo) - Codeunit 6789 “Withholding Tax Event Handler” (1 call:
AddCountryTables → AddTable)
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: "Calc. G/L Acc. Where-Used"), then bcatlas_get_procedure_body or bcatlas_get_neighbors on the returned id.