Budgeting
You can calculate a fee on net production costs plus the handling fee, and KOSMA recalculates the fee with every change in the budget.
A producer's fee is often calculated on the production costs plus the handling fee. In KOSMA, you add a markup whose **Base** contains both. You need a licence that lets you edit Budgeting, and a budget that is open in Budgeting and has at least one account. The example uses the budget How KOSMA Calculates in the Demo Project, with net production costs of 14,750.00.
Click **Overview/Markups** in the category list. KOSMA shows **Markups** below the categories.
Click  **Markup**. KOSMA adds a row and selects its description. Type `Handling fee` and press Enter. Double-click the cell in **Base**, type `NPC` and click outside the table. Double-click the cell in **%** and type `6`. KOSMA calculates a handling fee of 885.00. `NPC` stands for the net production costs: the sum of all accounts that are not deactivated, without the markups.
Click  **Markup** again, type `Fee` and press Enter. Double-click the cell in **Base**, type the following formula and click outside the table:
Double-click the cell in **%** and type `8`. The base of the fee shows 15,635.00, and the fee shows 1,250.80.
`1.06` stands for the costs plus the 6 % handling fee. In a formula, type a point as the decimal separator. When you change an account, KOSMA recalculates both markups.
If several markups need the costs plus the handling fee as their base, create this sum once as a variable. Click  **Variables** in the toolbar. KOSMA opens **Variables**.
1. Under **Groups**, click  **Group** to add a group. KOSMA adds a group named New Globals Group and selects its name. Type a name for the group. 2. Click  **Variable**. KOSMA adds a variable named New\_Global and puts the cursor in **Shorthand Name**. Type `NPC_Handling`. 3. Double-click the cell in **Calculation Formula**, type `NPC*1.06` and click outside the table. **Value** shows the net production costs plus the handling fee. 4. Click **Ok**. In **Markups**, double-click **Base** of the fee and replace `NPC*1.06` with `NPC_Handling`.
For more on groups and variables, see [create and organise variables](/kb/article/create-and-organise-variables).
You cannot use a variable whose formula contains `NPC` in an account or a subaccount.
**If you change the rate of the handling fee.** Without the variable, you type the rate of the handling fee twice: in **%** of the handling fee and in **Base** of the fee. For 5 %, type `5` in **%** of the handling fee and `NPC*1.05` in **Base** of the fee. With the variable, type `5` in **%** of the handling fee and change the **Calculation Formula** of the variable to `NPC*1.05`. KOSMA then recalculates every markup that uses the variable.
**Why a subtotal does not work as a base.** A subtotal that you add among the markups with  **Subtotal** adds up only the markups above it in its group, without the net production costs. KOSMA does not list it in **Variables**, and no formula can use it. Use a subtotal to show a sum in the budget. `GT`, the grand total with all markups, cannot be a base either, see [use budget totals as a markup base](/kb/article/use-budget-totals-as-a-markup-base).
Markdown