{"title":"Codeunit 5950 Service-Calc. Discount, events","url":"https://jonas-paprotka.de/ref/codeunit/5950-service-calc-discount/events/","author":"JOP-AL","license":"Metadata from Microsoft's symbol packages. AL source MIT, Copyright (c) Microsoft Corporation. Selection and wording © 2026 JOP-AL. https://jonas-paprotka.de/licenses/","subject":"Microsoft Dynamics 365 Business Central","checked":"2026-11-20","changed":"2026-10-05","object":{"type":"codeunit","id":5950,"name":"Service-Calc. Discount","app":"Base Application","versions":"17-29","url":"https://jonas-paprotka.de/ref/codeunit/5950-service-calc-discount/","json":"https://jonas-paprotka.de/ref/codeunit/5950-service-calc-discount.json"},"aspect":"events","total":12,"rows":[{"name":"OnAfterCalcServDiscount","sig":"(var Record Service Header)","named":"(var ServiceHeader: Record \"Service Header\")","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"17-21","first":17,"last":21,"obsoleteSince":null,"spans":[{"from":17,"to":21,"named":"(var ServiceHeader: Record \"Service Header\")","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnBeforeCalcServDiscount","sig":"(var Record Service Header)","named":"(var ServiceHeader: Record \"Service Header\")","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"17-22","first":17,"last":22,"obsoleteSince":null,"spans":[{"from":17,"to":22,"named":"(var ServiceHeader: Record \"Service Header\")","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnCalculateInvoiceDiscountOnAfterServiceLine2ValidateQuantity","sig":"(var Record Service Header, var Record Service Line, var Record Cust. Invoice Disc.)","named":"(var ServiceHeader: Record \"Service Header\"; var ServiceLine2: Record \"Service Line\"; var CustInvDisc: Record \"Cust. Invoice Disc.\")","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"19-29","first":19,"last":29,"obsoleteSince":null,"spans":[{"from":19,"to":29,"named":"(var ServiceHeader: Record \"Service Header\"; var ServiceLine2: Record \"Service Line\"; var CustInvDisc: Record \"Cust. Invoice Disc.\")","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnCalculateInvoiceDiscountOnBeforeServiceLine2Delete","sig":"(var Record Service Line)","named":"(var ServiceLine: Record \"Service Line\")","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"20-21","first":20,"last":21,"obsoleteSince":null,"spans":[{"from":20,"to":21,"named":"(var ServiceLine: Record \"Service Line\")","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnCalculateInvoiceDiscountOnBeforeServiceLineInsert","sig":"(var Record Service Line, Record Service Header)","named":"(var ServiceLine: Record \"Service Line\"; ServiceHeader: Record \"Service Header\")","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"20-29","first":20,"last":29,"obsoleteSince":null,"spans":[{"from":20,"to":29,"named":"(var ServiceLine: Record \"Service Line\"; ServiceHeader: Record \"Service Header\")","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnAfterCalcServDiscount","sig":"(var Record Service Header, var Record VAT Amount Line, var Record Service Line)","named":"(var ServiceHeader: Record \"Service Header\"; var TempVATAmountLine: Record \"VAT Amount Line\" temporary; var ServiceLine: Record \"Service Line\")","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"22-29","first":22,"last":29,"obsoleteSince":null,"spans":[{"from":22,"to":29,"named":"(var ServiceHeader: Record \"Service Header\"; var TempVATAmountLine: Record \"VAT Amount Line\" temporary; var ServiceLine: Record \"Service Line\")","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnCalculateInvoiceDiscountOnBeforeServiceLine2Delete","sig":"(var Record Service Line, Boolean, var Boolean)","named":"(var ServiceLine: Record \"Service Line\"; TemporaryHeader: Boolean; var IsHandled: Boolean)","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"22-29","first":22,"last":29,"obsoleteSince":null,"spans":[{"from":22,"to":29,"named":"(var ServiceLine: Record \"Service Line\"; TemporaryHeader: Boolean; var IsHandled: Boolean)","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnCalculateInvoiceDiscountOnBeforeApplyServiceCharge","sig":"(var Record Cust. Invoice Disc., var Record Service Header, Date, Decimal, var Boolean)","named":"(var CustInvoiceDisc: Record \"Cust. Invoice Disc.\"; var ServiceHeader: Record \"Service Header\"; CurrencyDate: Date; ChargeBase: Decimal; var ApplyServiceCharge: Boolean)","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"22-29","first":22,"last":29,"obsoleteSince":null,"spans":[{"from":22,"to":29,"named":"(var CustInvoiceDisc: Record \"Cust. Invoice Disc.\"; var ServiceHeader: Record \"Service Header\"; CurrencyDate: Date; ChargeBase: Decimal; var ApplyServiceCharge: Boolean)","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnCalculateInvoiceDiscountOnBeforeIsServiceChargeUpdated","sig":"(var Record Service Line, Record Customer Posting Group, var Boolean)","named":"(var ServiceLine: Record \"Service Line\"; CustomerPostingGroup: Record \"Customer Posting Group\"; var IsHandled: Boolean)","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"22-29","first":22,"last":29,"obsoleteSince":null,"spans":[{"from":22,"to":29,"named":"(var ServiceLine: Record \"Service Line\"; CustomerPostingGroup: Record \"Customer Posting Group\"; var IsHandled: Boolean)","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnBeforeCalcServDiscount","sig":"(var Record Service Header, var Record Service Line, var Record Service Line, Boolean, var Boolean)","named":"(var ServiceHeader: Record \"Service Header\"; var ServiceLine: Record \"Service Line\"; var ServiceLine2: Record \"Service Line\"; TemporaryHeader: Boolean; var IsHandled: Boolean)","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"23-29","first":23,"last":29,"obsoleteSince":null,"spans":[{"from":23,"to":29,"named":"(var ServiceHeader: Record \"Service Header\"; var ServiceLine: Record \"Service Line\"; var ServiceLine2: Record \"Service Line\"; TemporaryHeader: Boolean; var IsHandled: Boolean)","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnCalculateInvoiceDiscountOnAfterSetServiceLineFilters","sig":"(var Record Service Line)","named":"(var ServiceLine: Record \"Service Line\")","returns":"","kind":"integrationevent","access":"local","obsolete":null,"range":"26-29","first":26,"last":29,"obsoleteSince":null,"spans":[{"from":26,"to":29,"named":"(var ServiceLine: Record \"Service Line\")","returns":"","kind":"integrationevent","access":"local","obsolete":null}]},{"name":"OnCalculateInvoiceDiscountOnAfterApplyServiceCharge","sig":"(var Record Cust. Invoice Disc., var Record Service Header, var Record Service Line, Date, Boolean)","named":"(var CustInvoiceDisc: Record \"Cust. Invoice Disc.\"; var ServiceHeader: Record \"Service Header\"; var ServiceLine: Record \"Service Line\"; CurrencyDate: Date; TemporaryHeader: Boolean)","returns":"","kind":"internalevent","access":"local","obsolete":null,"range":"27-29","first":27,"last":29,"obsoleteSince":null,"spans":[{"from":27,"to":29,"named":"(var CustInvoiceDisc: Record \"Cust. Invoice Disc.\"; var ServiceHeader: Record \"Service Header\"; var ServiceLine: Record \"Service Line\"; CurrencyDate: Date; TemporaryHeader: Boolean)","returns":"","kind":"internalevent","access":"local","obsolete":null}]}]}