Table of Contents

KVSFCYRefreshProductionOrder

Procedures

InitializeRequest(Option, Boolean, Boolean, Boolean, Boolean, Boolean) :

Summary: Initializes the request parameters for refreshing production orders. This procedure configures all the options that control how production orders will be refreshed including scheduling direction, calculation scope, and confirmation settings. It allows programmatic setup of the refresh process without requiring user interaction through the request page.

procedure InitializeRequest(Direction2: Option; CalcLines2: Boolean; CalcRoutings2: Boolean; CalcComponents2: Boolean; CreateInbRqst2: Boolean; SetSuppressConfirm: Boolean): 

Parameters:

  • Direction2: The scheduling direction option (Forward or Backward) that determines how production order timing and dates are calculated during the refresh process.
  • CalcLines2: Indicates whether to calculate production order lines during refresh. When true, recreates all production order lines based on current BOM and routing definitions.
  • CalcRoutings2: Indicates whether to calculate routing lines during refresh. When true, recreates routing operations and capacity requirements. Must be true if CalcLines2 is true.
  • CalcComponents2: Indicates whether to calculate component requirements during refresh. When true, recreates component lines based on current BOM structure. Must be true if CalcLines2 is true.
  • CreateInbRqst2: Indicates whether to create inbound warehouse requests during refresh. When true, generates warehouse requests for production output handling.
  • SetSuppressConfirm: Indicates whether to suppress confirmation dialogs during refresh. When true, bypasses user prompts for operations like deleting picked component lines.

Events

OnAfterGetRoutingNo(Record Production Order, Code[20]) :

Summary: Event after getting routing number for production order.

[IntegrationEvent(false, false)]
local procedure OnAfterGetRoutingNo(var ProductionOrder: Record "Production Order"; var RoutingNo: Code[20]): 

Parameters:

  • ProductionOrder: Production order record.
  • RoutingNo: Routing number (output).

OnAfterRefreshProdOrder(Record Production Order, Boolean) :

Summary: Event after refreshing production order.

[IntegrationEvent(false, false)]
local procedure OnAfterRefreshProdOrder(var ProductionOrder: Record "Production Order"; ErrorOccured: Boolean): 

Parameters:

  • ProductionOrder: Production order record.
  • ErrorOccured: Indicates if error occurred.

OnBeforeCalcProdOrder(Record Production Order, Option) :

Summary: Event before calculating production order.

[IntegrationEvent(false, false)]
local procedure OnBeforeCalcProdOrder(var ProductionOrder: Record "Production Order"; Direction: Option): 

Parameters:

  • ProductionOrder: Production order record.
  • Direction: Scheduling direction option.

OnBeforeCalcProdOrderLine(Record Prod. Order Line, Option, Boolean, Boolean, Boolean, Boolean, Boolean) :

Summary: Event before calculating production order line.

[IntegrationEvent(false, false)]
local procedure OnBeforeCalcProdOrderLine(var ProdOrderLine: Record "Prod. Order Line"; Direction: Option; CalcLines: Boolean; CalcRoutings: Boolean; CalcComponents: Boolean; var IsHandled: Boolean; var ErrorOccured: Boolean): 

Parameters:

  • ProdOrderLine: Production order line record.
  • Direction: Scheduling direction option.
  • CalcLines: Calculate lines flag.
  • CalcRoutings: Calculate routings flag.
  • CalcComponents: Calculate components flag.
  • IsHandled: Set to true if handled.
  • ErrorOccured: Indicates if error occurred.

OnBeforeCalcProdOrderLines(Record Production Order, Option, Boolean, Boolean, Boolean, Boolean, Boolean) :

Summary: Event before calculating production order lines.

[IntegrationEvent(false, false)]
local procedure OnBeforeCalcProdOrderLines(var ProductionOrder: Record "Production Order"; Direction: Option; CalcLines: Boolean; CalcRoutings: Boolean; CalcComponents: Boolean; var IsHandled: Boolean; var ErrorOccured: Boolean): 

Parameters:

  • ProductionOrder: Production order record.
  • Direction: Scheduling direction option.
  • CalcLines: Calculate lines flag.
  • CalcRoutings: Calculate routings flag.
  • CalcComponents: Calculate components flag.
  • IsHandled: Set to true if handled.
  • ErrorOccured: Indicates if error occurred.

OnBeforeCalcRoutingsOrComponents(Record Production Order, Record Prod. Order Line, Boolean, Boolean, Boolean) :

Summary: Event before calculating routings or components for production order.

[IntegrationEvent(false, false)]
local procedure OnBeforeCalcRoutingsOrComponents(var ProductionOrder: Record "Production Order"; var ProdOrderLine: Record "Prod. Order Line"; var CalcComponents: Boolean; var CalcRoutings: Boolean; var IsHandled: Boolean): 

Parameters:

  • ProductionOrder: Production order record.
  • ProdOrderLine: Production order line record.
  • CalcComponents: Calculate components flag.
  • CalcRoutings: Calculate routings flag.
  • IsHandled: Set to true if handled.

OnBeforeUpdateRoutingNo(Record Production Order, Code[20], Boolean) :

Summary: Event before updating routing number for production order.

[IntegrationEvent(false, false)]
local procedure OnBeforeUpdateRoutingNo(var ProductionOrder: Record "Production Order"; RoutingNo: Code[20]; var IsHandled: Boolean): 

Parameters:

  • ProductionOrder: Production order record.
  • RoutingNo: Routing number.
  • IsHandled: Set to true if handled.

OnCheckReservationExistOnBeforeCheckProdOrderComp2ReservedQtyBase(Record Prod. Order Component) :

Summary: Event before checking reserved quantity base for production order component.

[IntegrationEvent(false, false)]
local procedure OnCheckReservationExistOnBeforeCheckProdOrderComp2ReservedQtyBase(var ProdOrderComp2: Record "Prod. Order Component"): 

Parameters:

  • ProdOrderComp2: Production order component record.