KVSKBACreatePurchaseOrderKFW
Procedures
DefDropShpt() :
Summary: Set's the Global Order Type to "Drop Shipment"
procedure DefDropShpt():
Remarks: This procedure sets the Global Order Type to "Drop Shipment". It is used to indicate that the purchase order being created is for a drop shipment. This procedure can be called before executing the report to ensure that the correct order type is set.
DefSpecialOrder() :
Summary: Set's the Global Order Type to "Special Order"
procedure DefSpecialOrder():
Remarks: This procedure sets the Global Order Type to "Special Order". It is used to indicate that the purchase order being created is for a special order. This procedure can be called before executing the report to ensure that the correct order type is set.
DefSales() :
Summary: Set's the Global Order Type to "Sales"
procedure DefSales():
Remarks: This procedure sets the Global Order Type to "Sales". It is used to indicate that the purchase order being created is for a sales order. This procedure can be called before executing the report to ensure that the correct order type is set.
DefService() :
Summary: Set's the Global Order Type to "Service"
procedure DefService():
Remarks: This procedure sets the Global Order Type to "Service". It is used to indicate that the purchase order being created is for a service order. This procedure can be called before executing the report to ensure that the correct order type is set.
DefOrderNo(Code[20]) :
Summary: Set's the Global Order No.
procedure DefOrderNo(NewOrderNo: Code[20]):
Parameters:
NewOrderNo: Order No. to set
Remarks: This procedure sets the Global Order No. to the specified value. It is used to indicate the order number for which the purchase order is being created. This procedure can be called before executing the report to ensure that the correct order number is set.
DefOrderNo(Code[20], Integer) :
Summary: Set's the Global Order No.
procedure DefOrderNo(NewOrderNo: Code[20]; NewLineNo: Integer):
Parameters:
NewOrderNo: Order No. to setNewLineNo: Line No. to set
Remarks: This procedure sets the Global Order No. and Line No. to the specified values. It is used to indicate the order number and line number for which the purchase order is being created. This procedure can be called before executing the report to ensure that the correct order number and line number are set.
GetVendorNo() :
Summary: Gets the vendor number for the sales lines of the specified order.
procedure GetVendorNo():
Remarks: This procedure retrieves the vendor number for the sales lines of the specified order. It checks the sales lines and retrieves the vendor number from the associated items. If multiple vendors are found, it sets the appropriate flags and clears the main vendor number. This procedure is used to determine the vendor for creating purchase orders based on the sales order.
GetVendorNos() :
Summary: Gets the vendor numbers for the sales lines of the specified order.
procedure GetVendorNos():
Remarks: This procedure retrieves the vendor numbers for the sales lines of the specified order. It checks the sales lines and retrieves the vendor numbers from the associated items. If multiple vendors are found, it sets the appropriate flags and clears the main vendor number. This procedure is used to determine the vendors for creating purchase orders based on the sales order.
Events
OnBeforeSalesHeaderOnAfterGetRecord(Record Sales Header, Option, Code[20], Code[20], Boolean, List, Boolean, Boolean, Boolean) :
[IntegrationEvent(false, false)]
local procedure OnBeforeSalesHeaderOnAfterGetRecord(var SalesHeader: Record "Sales Header"; var OrderType: Option; var OrderNo: Code[20]; var VendorNo: Code[20]; var SkipStandardCode: Boolean; var VendorNoList: List; var MultipleVendors: Boolean; var VendorwithNoItemNoExist: Boolean; var SelectOneVendor: Boolean):
OnBeforeSetNoteText(Text, Boolean) :
Summary: Integration event for handling note text processing.
[IntegrationEvent(false, false)]
local procedure OnBeforeSetNoteText(var NoteText: Text; var IsHandled: Boolean):
Parameters:
NoteText: The note text to be set for the report.IsHandled: Indicates whether the event has been handled by the subscriber.
Remarks: This integration event is raised before setting note text. It allows subscribers to intercept and customize the handling of note text.
OnBeforeSetFilterSalesLines(Record Sales Line, Boolean) :
Summary: Integration event for handling sales line filtering.
[IntegrationEvent(false, false)]
local procedure OnBeforeSetFilterSalesLines(var SalesLine: Record "Sales Line"; var IsHandled: Boolean):
Parameters:
SalesLine: The sales line record to be filtered.IsHandled: Indicates whether the event has been handled.
Remarks: This integration event is raised before filtering sales lines. It allows subscribers to intercept and customize the filtering of sales line data.
OnBeforeFindSalesLines(Record Sales Line, Boolean) :
Summary: Integration event for handling sales line finding.
[IntegrationEvent(false, false)]
local procedure OnBeforeFindSalesLines(var SalesLine: Record "Sales Line"; var IsHandled: Boolean):
Parameters:
SalesLine: The sales line record being processed.IsHandled: Indicates whether the event has been handled.
Remarks: This integration event is raised before finding sales lines. It allows subscribers to intercept and customize the handling of sales line data.
OnBeforeGetItemVendorNo(Record Sales Line, Code[20], Boolean) :
Summary: Integration event for handling item vendor number retrieval for sales lines.
[IntegrationEvent(false, false)]
local procedure OnBeforeGetItemVendorNo(SalesLine: Record "Sales Line"; var ItemVendorNo: Code[20]; var IsHandled: Boolean):
Parameters:
SalesLine: The sales line record for which the vendor number is being retrieved.ItemVendorNo: The vendor number associated with the item in the sales line.IsHandled: Indicates whether the event has been handled.
Remarks: This integration event is raised before retrieving the vendor number for a specific sales line. It allows subscribers to intercept and customize the retrieval of vendor numbers based on sales line data.
OnBeforeGetVendorNo(Code[20], Boolean) :
Summary: Integration event for handling vendor number retrieval for sales lines.
[IntegrationEvent(false, false)]
local procedure OnBeforeGetVendorNo(var MainVendorNo: Code[20]; var IsHandled: Boolean):
Parameters:
MainVendorNo: The main vendor number found for the sales lines.IsHandled: Indicates whether the event has been handled.
Remarks: This integration event is raised before retrieving the vendor number for sales lines. It allows subscribers to intercept and customize the retrieval of the vendor number based on sales line data.
OnBeforeGetVendorNos(Boolean, Boolean, Boolean, List, Code[20], Boolean) :
[IntegrationEvent(false, false)]
local procedure OnBeforeGetVendorNos(var MultipleVendors: Boolean; var SelectOneVendor: Boolean; var VendorwithNoItemNoExist: Boolean; var VendorNoList: List; var MainVendorNo: Code[20]; var IsHandled: Boolean):
OnBeforeServiceHeaderOnAfterGetRecord(Record Service Header, Option, Code[20], Integer, Code[20], Boolean, List, Boolean, Boolean, Boolean) :
[IntegrationEvent(false, false)]
local procedure OnBeforeServiceHeaderOnAfterGetRecord(ServiceHeader: Record "Service Header"; GlobalOrderType: Option; OrderNo: Code[20]; LineNo: Integer; MainVendorNo: Code[20]; var IsHandled: Boolean; VendorNoList: List; MultipleVendors: Boolean; VendorwithNoItemNoExist: Boolean; SelectOneVendor: Boolean):
OnBeforeSetFilterServiceLines(Record Service Line, Boolean) :
Summary: Integration event for handling service line filtering.
[IntegrationEvent(false, false)]
local procedure OnBeforeSetFilterServiceLines(var ServiceLine: Record "Service Line"; var IsHandled: Boolean):
Parameters:
ServiceLine: The service line record to be filtered.IsHandled: Indicates whether the event has been handled.
Remarks: This integration event is raised before setting filters on service lines. It allows subscribers to intercept and customize the filtering of service line data based on specific criteria.
OnBeforeFindServiceLines(Record Service Line, Boolean) :
Summary: Integration event for handling service line processing.
[IntegrationEvent(false, false)]
local procedure OnBeforeFindServiceLines(var ServiceLine: Record "Service Line"; var IsHandled: Boolean):
Parameters:
ServiceLine: The service line record to be processed.IsHandled: Indicates whether the event has been handled.
Remarks: This integration event is raised before finding service lines. It allows subscribers to intercept and customize the handling of service line data.
OnBeforeGetItemVendorNoService(Record Service Line, Code[20], Boolean) :
Summary: Integration event for handling item vendor number retrieval for service lines.
[IntegrationEvent(false, false)]
local procedure OnBeforeGetItemVendorNoService(ServiceLine: Record "Service Line"; var ItemVendorNo: Code[20]; var IsHandled: Boolean):
Parameters:
ServiceLine: The service line record for which the vendor number is being retrieved.ItemVendorNo: The vendor number associated with the item in the service line.IsHandled: Indicates whether the event has been handled.
Remarks: This integration event is raised before retrieving the vendor number for a specific service line. It allows subscribers to intercept and customize the retrieval of vendor numbers based on service line data.
OnBeforeGetItemVendorNoItemNo(Code[20], Code[20], Boolean) :
Summary: Integration event for handling item vendor number retrieval.
[IntegrationEvent(false, false)]
local procedure OnBeforeGetItemVendorNoItemNo(ItemNo: Code[20]; var ItemVendorNo: Code[20]; var IsHandled: Boolean):
Parameters:
ItemNo: The item number for which the vendor number is being retrieved.ItemVendorNo: The vendor number associated with the specified item number.IsHandled: Indicates whether the event has been handled.
Remarks: This integration event is raised before retrieving the vendor number for a specific item. It allows subscribers to intercept and customize the retrieval of vendor numbers based on item numbers.