Calendars and MiscellaneousInvoice: Odd percentage error in subtotal (and total)

Calendars, invoices, tables, memos, contracts, dictionaries, code snippets
Post Reply
visvaji
Posts: 2
Joined: Fri Apr 10, 2015 10:07 am

Invoice: Odd percentage error in subtotal (and total)

Post by visvaji »

I have just started with the invoice class. Exactly what I need.

However there is an odd percentage error in the subtotal, and total. This is an example:

Code: Select all

\begin{invoiceTable}
\feetype{bla bla}
\hourrow{bla bla}{1.0}{180}
\hourrow{bla bla}{0.5}{180}
\hourrow{bla bla}{0.20}{180}
\hourrow{bla bla}{0.20}{180}
\hourrow{bla bla}{0.5}{180}
\subtotal*

\feetype{bla bla}
\hourrow{bla bla}{0.5}{180}
\hourrow{bla bla}{0.5}{180}
\subtotal*
The result is:
bla bla 1.00 Std. 180.00 180.00
bla bla 0.50 Std. 180.00 90.00
bla bla 0.20 Std. 180.00 36.00
bla bla 0.20 Std. 180.00 36.00
bla bla 0.50 Std. 180.00 90.00
Teilsumme 431.64
Why not 432.00?

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics TikZによるLaTeXグラフィックス
visvaji
Posts: 2
Joined: Fri Apr 10, 2015 10:07 am

Invoice: Odd percentage error in subtotal (and total)

Post by visvaji »

Saw this warning http://www.barik.net/archive/2004/11/08/200700/ and played with the number of hours. For example, 0.25 or 0.30 hours don't have the problem. It is a rounding problem after all.

Any explanations?
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Invoice: Odd percentage error in subtotal (and total)

Post by Johannes_B »

Hi and welcome,

i filed an issue report with the developer on github. The problem is known and i bumped it once more. Let's hope he adjusts the class.

There is one problem though, the class provided at LaTeX-templates is an older version, incompatible to the current version.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
Post Reply