codeunitManufacturingofficial - Microsoftderived - from the source, no model text

Codeunit 5812 "Calculate Standard Cost"

Base Application · Microsoft.Manufacturing.StandardCost

Across versions

  1. BC23present
  2. BC244 events added, 1 events removed
  3. BC251 procedures added, 1 events added
  4. BC2619 procedures added, 3 events removed
  5. BC273 procedures changed
  6. BC287 events added, 2 events removed
  7. BC292 events added, 1 events removed
  8. BC302 procedures removed

Neighbourhood 10 connected objects and pages

Codeunit 20514 "Subc. Calc.StandardCost Ext." (event subscribers, 3 links)Subc. Calc.StandardCost Ext.Codeunit 99000758 "Mfg. Cost Calculation Mgt." (calls, 8 links)Mfg. Cost Calculation Mgt.Codeunit 5402 "Unit of Measure Management" (calls, 6 links)Unit of Measure ManagementCodeunit 5836 "Cost Calculation Management" (calls, 6 links)Cost Calculation ManagementCodeunit 5804 "ItemCostManagement" (calls, 3 links)ItemCostManagementCodeunit 4770 "Create Mfg Item" (calls, 2 links)Create Mfg ItemCodeunit 99000756 "VersionManagement" (calls, 2 links)VersionManagementCodeunit 99000762 "Mfg. Item Journal Mgt." (calls, 2 links)Mfg. Item Journal Mgt.Report extension 99000781 "Mfg. CalcInventoryValueTest" (calls, 2 links)Mfg. CalcInventoryValueTestCodeunit 7001 "Price Calculation Mgt." (calls)Price Calculation Mgt.

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.Manufacturing.StandardCost · BC23-30 · source at ea08af5e · facts from BC29

Events published

  • OnAfterCalcRtngLineCost(RoutingLine: Record "Routing Line"; MfgItemQtyBase: Decimal; var SLCap: Decimal; var SLSub: Decimal; var SLCapOvhd: Decimal; var StdCostWkshName: Text[50]; var ParentItem: Record Item; CostTime: Decimal; var DirUnitCost: Decimal) + BC25 − BC25 + BC29 − BC29 (integration)
  • OnCalcRtngCostSKUOnBeforeCalcRtngLineCostSKU(var RoutingLine: Record "Routing Line"; MfgItemQtyBase: Decimal; var SLCap: Decimal; var SLSub: Decimal; var SLCapOvhd: Decimal; var IsHandled: Boolean) + BC29 (integration)
  • OnAfterSetProdBOMFilters(var ProdBOMLine: Record "Production BOM Line"; var PBOMVersionCode: Code[20]; var ProdBOMNo: Code[20]) (integration)
  • OnAfterSetProperties(var NewCalculationDate: Date; var NewCalcMultiLevel: Boolean; var NewUseAssemblyList: Boolean; var NewLogErrors: Boolean; var NewStdCostWkshName: Text[50]; var NewShowDialog: Boolean) (integration)
  • OnBeforeCalcItems(var Item: Record Item) (integration)
  • OnCalcItemsOnBeforeProcessItems(var Item2: Record Item; var NewTempItem: Record Item; var IsHandled: Boolean) + BC28 (integration)
  • OnBeforeCalcItem(var Item: Record Item; UseAssemblyList: Boolean; var IsHandled: Boolean) (integration)
  • OnBeforeCalcMfgItem(var Item: Record Item; var LogErrors: Boolean; StdCostWkshName: Text[50]) (integration)
  • OnBeforeCalcRtngLineCost(var RoutingLine: Record "Routing Line"; MfgItemQtyBase: Decimal; var ParentItem: Record Item) + BC28 − BC28 (integration)
  • OnCalcAssemblyItemOnAfterInitItemCost(var Item: Record Item) (integration)
  • OnCalcAssemblyItemOnAfterCalcItemRolledupCost(var Item: Record Item) (integration)
  • OnBeforeTestBOMVersionIsCertified(BOMVersionCode: Code[20]; ProductionBOMHeader: Record "Production BOM Header"; LogErrors: Boolean; var IsHandled: Boolean) (integration)
  • OnBeforeTestRtngVersionIsCertified(RtngVersionCode: Code[20]; RoutingHeader: Record "Routing Header"; LogErrors: Boolean; var IsHandled: Boolean) (integration)
  • OnCalcAssemblyItemOnAfterCalcSingleLevelCost(var Item: Record Item) (integration)
  • OnCalcAssemblyItemOnAfterCalcItemCost(var Item: Record Item; CompItem: Record Item; BOMComponent: Record "BOM Component"; var ComponentQuantity: Decimal; var Level: Integer; var CalcMfgItems: Boolean) + BC28 − BC28 (integration)
  • OnCalcItemOnBeforeShowStrMenu(var Item: Record Item; var ShowStrMenu: Boolean; var NewCalcMultiLevel: Boolean) (integration)
  • OnCalcItemOnAfterCalcShowConfirm(Item: Record Item; var CalcMfgItems: Boolean; var ShowConfirm: Boolean) (integration)
  • OnCalcMfgItemOnBeforeCalcRtngCost(var Item: Record Item; Level: Integer; var LotSize: Decimal; var MfgItemQtyBase: Decimal; var SLCap: Decimal) + BC26 − BC26 (integration)
  • OnCalcMfgItemOnBeforeCalculateCosts(var SLMat: Decimal; var SLCap: Decimal; var SLSub: Decimal; var SLCapOvhd: Decimal; var SLMfgOvhd: Decimal; var Item: Record Item; LotSize: Decimal; MfgItemQtyBase: Decimal; Level: Integer; CalculationDate: Date; var RUMat: Decimal) (integration)
  • OnCalcMfgItemOnAfterCalculateCosts(SingleLevelMaterial: Decimal; SingleLevelCapacity: Decimal; SingleLevelSubcontracted: Decimal; SingleLevelCapacityOverhead: Decimal; SingleLevelMfgOverhead: Decimal; var Item: Record Item; LotSize: Decimal; MfgItemQtyBase: Decimal; Level: Integer; CalculationDate: Date; RolledUpMaterial: Decimal) + BC28 (integration)
  • OnCalcProdBOMCostOnAfterCalcCompItemQtyBase(CalculationDate: Date; MfgItem: Record Item; MfgItemQtyBase: Decimal; IsTypeItem: Boolean; var ProdBOMLine: Record "Production BOM Line"; var CompItemQtyBase: Decimal; RtngNo: Code[20]; UOMFactor: Decimal) (integration)
  • OnCalcProdBOMCostOnAfterCalcMfgItem(var ProdBOMLine: Record "Production BOM Line"; MfgItem: Record Item; MfgItemQtyBase: Decimal; CompItem: Record Item; CompItemQtyBase: Decimal; Level: Integer; IsTypeItem: Boolean; UOMFactor: Decimal; var ParentItem: Record Item) (integration)
  • OnCalcProdBOMCostOnAfterCalcAnyItem(var ProductionBOMLine: Record "Production BOM Line"; MfgItem: Record Item; MfgItemQtyBase: Decimal; CompItem: Record Item; CompItemQtyBase: Decimal; Level: Integer; IsTypeItem: Boolean; UOMFactor: Decimal; var SLMat: Decimal; var RUMat: Decimal; var RUCap: Decimal; var RUSub: Decimal; var RUCapOvhd: Decimal; var RUMfgOvhd: Decimal) (integration)
  • OnCalcRtngCostOnBeforeCalcRtngLineCost(var RoutingLine: Record "Routing Line"; ParentItem: Record Item; var LogErrors: Boolean; var IsHandled: Boolean) + BC24 − BC24 (integration)
  • OnCalcRoutingCostPerUnitOnBeforeCalc(Type: Enum "Capacity Type Routing"; var DirUnitCost: Decimal; var IndirCostPct: Decimal; var OvhdRate: Decimal; var UnitCost: Decimal; var UnitCostCalculation: Enum "Unit Cost Calculation Type"; WorkCenter: Record "Work Center"; MachineCenter: Record "Machine Center"; var IsHandled: Boolean) (integration)
  • OnGetWorkCenterOnBeforeAssignWorkCenterToTemp(var WorkCenter: Record "Work Center"; var TempItem: Record Item temporary; StdCostWkshName: Text[50]) + BC26 − BC26 (integration)
  • OnAfterGetItem(var Item: Record Item; StdCostWkshName: Text[50]; IsInBuffer: Boolean) (integration)
  • OnBeforeSetProperties(var NewCalculationDate: Date; var NewCalcMultiLevel: Boolean; var NewUseAssemblyList: Boolean; var NewLogErrors: Boolean; var NewStdCostWkshName: Text[50]; var NewShowDialog: Boolean) (integration)
  • OnBeforeCalcProdBOMCost(MfgItem: Record Item; ProdBOMNo: Code[20]; RtngNo: Code[20]; MfgItemQtyBase: Decimal; IsTypeItem: Boolean; Level: Integer; var SLMat: Decimal; var RUMat: Decimal; var RUCap: Decimal; var RUSub: Decimal; var RUCapOvhd: Decimal; var RUMfgOvhd: Decimal; var IsHandled: Boolean; var CalculationDate: Date; var LogErrors: Boolean; var TempRoutingVersion: Record "Routing Version" temporary; var TempProductionBOMVersion: Record "Production BOM Version" temporary) (integration)
  • OnBeforeDoCalcAssemblyItemPrice(var Item: Record Item; Level: Integer; MaxLevel: Integer; CalcMultiLevel: Boolean; var IsHandled: Boolean) (integration)
  • OnDoCalcAssemblyItemPriceOnAfterSetBOMCompFilters(var Item: Record Item; var BOMComponent: Record "BOM Component") (integration)
  • OnCalcProdBOMCostOnBeforeCalcCompItemQtyBase(var ProductionBOMLine: Record "Production BOM Line"; var ParentItem: Record Item; CalculationDate: Date; MfgItem: Record Item; MfgItemQtyBase: Decimal; IsTypeItem: Boolean; var CompItemQtyBase: Decimal; RtngNo: Code[20]; UOMFactor: Decimal) (integration)
  • OnGetResCostOnBeforeAssignPriceListLineToTemp(var PriceListLine: Record "Price List Line"; var TempItem: Record Item temporary; StdCostWkshName: Text[50]) + BC24 (integration)
  • OnGetMachineCenterOnBeforeAssignMachineCenterToTemp(var MachineCenter: Record "Machine Center"; var TempItem: Record Item temporary; StdCostWkshName: Text[50]) + BC24 (integration)
  • OnCalcRtngLineCostOnAfterCalcRoutingCostPerUnit(RoutingLine: Record "Routing Line"; WorkCenter: Record "Work Center"; var MfgItemQtyBase: Decimal; var UnitCostCalculation: Enum "Unit Cost Calculation Type") + BC24 (integration)
  • OnCalcRtngLineCostOnBeforeCalcRoutingCostPerUnit(var RoutingLine: Record "Routing Line"; MfgItemQtyBase: Decimal; var WorkCenter: Record "Work Center"; var DirUnitCost: Decimal; var IndirCostPct: Decimal; var OvhdRate: Decimal; var UnitCost: Decimal; var UnitCostCalculation: Enum "Unit Cost Calculation Type"; var ParentItem: Record Item; var IsHandled: Boolean) + BC28 (integration)
  • OnCalcItemOnAfterCalculateCosts(var Item: Record Item) + BC28 (integration)
  • OnCalcProdBOMCostOnBeforeNextLineIteration(var ProductionBOMLine: Record "Production BOM Line"; PBOMVersionCode: Code[20]; Level: Integer; CompItemQtyBase: Decimal; CompItem: Record Item; SLMat: Decimal) + BC28 (integration)

Event subscriptions

  • OnValidateNoByType subscribes to Table “Standard Cost Worksheet” OnAfterValidateEvent (No.)

Procedures

  • SetProperties(NewCalculationDate: Date; NewCalcMultiLevel: Boolean; NewUseAssemblyList: Boolean; NewLogErrors: Boolean; NewStdCostWkshName: Text[50]; NewShowDialog: Boolean)
  • TestPreconditions(var Item: Record Item; var TempNewProductionBOMVersion: Record "Production BOM Version" temporary; var NewRtngVersionErrBuf: Record "Routing Version")
  • CalcItem(ItemNo: Code[20]; NewUseAssemblyList: Boolean)
  • CalcItemForNonInventoryValue(var Item: Record Item) + BC26 Δ BC27 − BC30 (obsolete 27.0: procedure that was implemented to throw the error has now been identified as unnecessary)
  • CalcSKUForNonInventoryValue(var SKU: Record "Stockkeeping Unit") + BC26 Δ BC27 − BC30 (obsolete 27.0: procedure that was implemented to throw the error has now been identified as unnecessary)
  • CalcItemSKU(ItemNo: Code[20]; LocationCode: Code[20]; VariantCode: Code[20]) + BC26
  • CalcItems(var Item: Record Item; var NewTempItem: Record Item)
  • CalcAssemblyItemPrice(ItemNo: Code[20])
  • CalculateAssemblyCostExp(AssemblyHeader: Record "Assembly Header"; var ExpCost: array[5] of Decimal)
  • CalcOverHeadAmt(CostAmt: Decimal; IndirectCostPct: Decimal; OverheadRateAmt: Decimal): Decimal
  • CalcAsmOrderStatistics(AssemblyHeader: Record "Assembly Header"; var Value: array[5, 5] of Decimal)
  • CalcPostedAsmOrderStatistics(PostedAssemblyHeader: Record "Posted Assembly Header"; var Value: array[5, 5] of Decimal)
  • CalcRtngLineCost(RoutingLine: Record "Routing Line"; MfgItemQtyBase: Decimal; var SLCap: Decimal; var SLSub: Decimal; var SLCapOvhd: Decimal) + BC25
  • CalcRtngLineCost(RoutingLine: Record "Routing Line"; MfgItemQtyBase: Decimal; var SLCap: Decimal; var SLSub: Decimal; var SLCapOvhd: Decimal; var ParentItem: Record Item) + BC25 (internal)
  • CalcRtngLineCostSKU(RoutingLine: Record "Routing Line"; MfgItemQtyBase: Decimal; var SLCap: Decimal; var SLSub: Decimal; var SLCapOvhd: Decimal) + BC26 (internal)
  • RunOnBeforeCalcItems(var Item: Record Item) + BC26 (internal)
  • RunOnBeforeCalcItem(var Item: Record Item; UseAssemblyList: Boolean; var IsHandled: Boolean) + BC26 (internal)
  • RunOnCalcAssemblyItemOnAfterInitItemCost(var Item: Record Item) + BC26 (internal)
  • RunOnCalcAssemblyItemOnAfterCalcItemRolledupCost(var Item: Record Item) + BC26 (internal)
  • RunOnCalcAssemblyItemOnAfterCalcSingleLevelCost(var Item: Record Item) + BC26 (internal)
  • RunOnCalcAssemblyItemOnAfterCalcItemCost(var Item: Record Item; CompItem: Record Item; BOMComponent: Record "BOM Component"; ComponentQuantity: Decimal) + BC26 (internal)
  • RunOnAfterGetItem(var Item: Record Item; StdCostWkshName: Text[50]; IsInBuffer: Boolean) + BC26 (internal)
  • RunOnBeforeDoCalcAssemblyItemPrice(var Item: Record Item; Level: Integer; MaxLevel: Integer; CalcMultiLevel: Boolean; var IsHandled: Boolean) + BC26 (internal)
  • RunOnDoCalcAssemblyItemPriceOnAfterSetBOMCompFilters(var Item: Record Item; var BOMComponent: Record "BOM Component") + BC26 (internal)

Plus 30 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.

Called by

Recent changes

Countries that replace it

IT

Deprecations

  • procedure CalcItemForNonInventoryValue: Pending 27.0 (#if not CLEAN27), “procedure that was implemented to throw the error has now been identified as unnecessary”
  • procedure CalcSKUForNonInventoryValue: Pending 27.0 (#if not CLEAN27), “procedure that was implemented to throw the error has now been identified as unnecessary”

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

Evidence 1 sources