---
title: "Codeunit 5807 Item Charge Assgnt. (Sales), extension points 29"
author: "JOP-AL"
url: https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/points/
object: https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/
app: "Base Application"
major: 29
source: https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/
checked: 2026-11-20
changed: 2026-10-13
subject: "Microsoft Dynamics 365 Business Central"
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/"
---

# Codeunit 5807 Item Charge Assgnt. (Sales), extension points 29

JOP-AL, https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/points/

19 procedures and triggers with a step in src/Layers/W1/BaseApp/Sales/Document/ItemChargeAssgntSales.Codeunit.al, in source order, read from the text, not from a run.

## InsertItemChargeAssignment

[Line 47](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L47).

- [49](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L49) calls `InsertItemChargeAssignmentWithValues`

## InsertItemChargeAssignmentWithValues

[Line 65](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L65).

- [69](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L69) calls `InsertItemChargeAssignmentWithValuesTo`

## InsertItemChargeAssignmentWithValuesTo

[Line 87](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L87).

- [92](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L92) raises `OnBeforeInsertItemChargeAssignmentWithValuesTo`
- [111](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L111) validates [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) `Qty. to Assign`
- [113](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L113) raises `OnBeforeInsertItemChargeAssgntWithAssignValues`
- [114](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L114) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Insert

## Summarize

[Line 122](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L122).

- [132](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L132) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Insert
- [145](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L145) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Insert

## CreateDocChargeAssgn

[Line 153](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L153).

- [159](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L159) raises `OnBeforeCreateDocChargeAssgn`
- [164](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L164) raises `OnCreateDocChargeAssgnOnAfterFromSalesLineSetFilters`
- [180](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L180) calls `InsertItemChargeAssignment`
- [188](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L188) raises `OnAfterCreateDocChargeAssgnt`

## CreateShptChargeAssgnt

[Line 196](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L196).

- [203](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L203) raises `OnBeforeCreateShptChargeAssgnt`
- [215](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L215) raises `OnCreateShptChargeAssgntOnBeforeTestJobNo`
- [221](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L221) calls `InsertItemChargeAssignment`

## CreateRcptChargeAssgnt

[Line 233](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L233).

- [249](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L249) calls `InsertItemChargeAssignment`

## SuggestAssignment

[Line 275](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L275).

- [292](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L292) raises `OnSuggestAssignmentOnBeforeSelectionItemChargeAssign`
- [298](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L298) calls `AssignEquallyMenuText`
- [298](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L298) calls `AssignByAmountMenuText`
- [298](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L298) calls `AssignByWeightMenuText`
- [298](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L298) calls `AssignByVolumeMenuText`
- [302](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L302) raises `OnBeforeShowSuggestItemChargeAssignStrMenu`
- [314](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L314) raises `OnSuggestAssignmentOnBeforeAssignItemCharges`
- [315](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L315) calls `AssignItemCharges`

## AssignItemCharges

[Line 325](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L325).

- [327](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L327) calls `GetSelectionText`

## GetSelectionText

[Line 330](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L330), local.

- [335](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L335) calls `AssignEquallyMenuText`
- [335](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L335) calls `AssignByAmountMenuText`
- [335](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L335) calls `AssignByWeightMenuText`
- [335](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L335) calls `AssignByVolumeMenuText`

## AssignItemCharges

[Line 360](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L360).

- [369](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L369) raises `OnBeforeAssignItemCharges`, IsHandled
- [375](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L375) calls [Table 4 Currency](https://jonas-paprotka.de/ref/table/4-currency/) `InitRoundingPrecision`
- [381](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L381) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) ModifyAll
- [382](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L382) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) ModifyAll
- [383](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L383) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) ModifyAll
- [384](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L384) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) ModifyAll
- [388](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L388) calls `AssignEquallyMenuText`
- [389](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L389) calls `AssignEqually`
- [390](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L390) calls `AssignByAmountMenuText`
- [391](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L391) calls `AssignByAmount`
- [392](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L392) calls `AssignByWeightMenuText`
- [393](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L393) calls `AssignByWeight`
- [394](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L394) calls `AssignByVolumeMenuText`
- [395](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L395) calls `AssignByVolume`
- [397](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L397) raises `OnAssignItemCharges`

## AssignEqually

[Line 442](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L442), local.

- [448](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L448) calls [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) `SalesLineInvoiced`
- [451](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L451) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Insert
- [464](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L464) calls [Codeunit 5402 Unit of Measure Management](https://jonas-paprotka.de/ref/codeunit/5402-unit-of-measure-management/) `QtyRndPrecision`
- [476](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L476) raises `OnAssignEquallyOnBeforeItemChargeAssignmentSalesModify`
- [477](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L477) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Modify
- [480](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L480) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) DeleteAll

## AssignByAmount

[Line 483](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L483), local.

- [495](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L495) calls [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) `SalesLineInvoiced`
- [506](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L506) raises `OnAssignByAmountOnBeforeGetSalesLine`
- [520](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L520) calls [Table 6661 Return Receipt Line](https://jonas-paprotka.de/ref/table/6661-return-receipt-line/) `GetCurrencyCode`
- [526](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L526) calls [Table 330 Currency Exchange Rate](https://jonas-paprotka.de/ref/table/330-currency-exchange-rate/) `ExchangeAmtFCYToFCY`
- [535](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L535) calls [Table 111 Sales Shipment Line](https://jonas-paprotka.de/ref/table/111-sales-shipment-line/) `GetCurrencyCode`
- [541](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L541) calls [Table 330 Currency Exchange Rate](https://jonas-paprotka.de/ref/table/330-currency-exchange-rate/) `ExchangeAmtFCYToFCY`
- [546](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L546) raises `OnAssignByAmountOnAfterAssignAppliesToDocLineAmount`
- [548](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L548) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Insert
- [554](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L554) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Modify
- [560](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L560) raises `OnAssignByAmountOnBeforeModifyItemChargeAssignmentSalesLoop`
- [573](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L573) calls [Codeunit 5402 Unit of Measure Management](https://jonas-paprotka.de/ref/codeunit/5402-unit-of-measure-management/) `QtyRndPrecision`
- [585](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L585) raises `OnAssignByAmountOnBeforeItemChargeAssignmentSalesModify`
- [586](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L586) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Modify
- [590](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L590) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) DeleteAll

## AssignByWeight

[Line 593](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L593), local.

- [602](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L602) calls [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) `SalesLineInvoiced`
- [605](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L605) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Insert
- [606](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L606) calls `GetItemValues`
- [610](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L610) raises `OnAssignByWeightOnAfterCalcTotalGrossWeight`
- [615](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L615) calls `GetItemValues`
- [622](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L622) calls `AssignSalesItemCharge`
- [624](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L624) raises `OnAssignByWeightOnBeforeTempItemChargeAssgntSalesDelete`
- [625](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L625) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) DeleteAll

## AssignByVolume

[Line 628](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L628), local.

- [637](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L637) calls [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) `SalesLineInvoiced`
- [640](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L640) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Insert
- [641](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L641) calls `GetItemValues`
- [650](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L650) calls `GetItemValues`
- [657](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L657) calls `AssignSalesItemCharge`
- [659](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L659) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) DeleteAll

## AssignSalesItemCharge

[Line 670](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L670).

- [678](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L678) calls [Codeunit 5402 Unit of Measure Management](https://jonas-paprotka.de/ref/codeunit/5402-unit-of-measure-management/) `QtyRndPrecision`
- [688](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L688) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Modify

## GetItemValues

[Line 696](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L696).

- [731](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L731) raises `OnAfterGetItemValues`

## SuggestAssignmentFromLine

[Line 738](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L738).

- [753](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L753) calls [Table 4 Currency](https://jonas-paprotka.de/ref/table/4-currency/) `InitRoundingPrecision`
- [755](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L755) calls `GetItemChargeAssgntLineAmounts`
- [766](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L766) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Modify
- [787](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L787) calls [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) `SalesLineInvoiced`
- [789](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L789) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Insert
- [814](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L814) writes [Table 5809 Item Charge Assignment (Sales)](https://jonas-paprotka.de/ref/table/5809-item-charge-assignment-sales/) Modify

## GetItemChargeAssgntLineAmounts

[Line 822](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L822), local.

- [830](https://jonas-paprotka.de/ref/codeunit/5807-item-charge-assgnt-sales/source/#L830) calls [Table 4 Currency](https://jonas-paprotka.de/ref/table/4-currency/) `InitRoundingPrecision`

## Source

AL source 29: https://github.com/microsoft/BCApps, MIT, releases/29.x at 4303e5e584d3aa5d9e98cbc615525a5396ad6ed7.

JOP-AL, 2026-11-20.
