# AF-0076

Source: https://xmlvalid.com/rules/AF-0076

> Der angegebene Wert ist ungültig. Die Gesamtbruttosumme der Rechnung (…) entspricht nicht der Summe der Bruttosummen der Details +/- globale Auf-/Abschläge (…).

- Level: error
- Rule sets: e-Rechnung.gv.at checks (ebInterface) Fehlerliste, October 2026
- Context: `/*:Invoice`
- Test: `abs($payable - $total) le 0.01`

In English: The invoice total (PayableAmount) does not match the sum of the tax summary: taxable amounts and VAT, other taxes, less the amount paid in advance, plus rounding and amounts below the line.

## Why it fails

- A line or a VAT amount was changed after the total was calculated.
- `PayableAmount` was left at 0, or holds the net amount.

## How to fix it

- Recalculate `PayableAmount` as the sum of `TaxableAmount` and `TaxAmount` of each `Tax/TaxItem`, plus `OtherTax`, minus `PrepaidAmount`, plus `RoundingAmount`.

Validate a document against these rules: https://xmlvalid.com/validate
