juh via ntg-context schrieb am 12.11.2021 um 12:20:
Dear all,
I thought I could find my way through the spreadsheet documentation to make my invoices.
While it is simple to calculate the sum or the product of two cells if you know that they are A[2] and B[2] I can't find the solution to access cell A and B *on the same row*.
Amount | Single | Sum 2 | 5 | 10 <-- A[currentrow] * B[currentrow] does not work 3 | 4 | 12 ==================== Sum 22
The rows come from a script and there might be several items.
Any hints?
Do you have a example because I have no problem to access values in the current row. \usemodule[spreadsheet] \starttext \bTABLE \bTR \bTD Amount \eTD \bTD Single \eTD \bTD Sum \eTD \eTR \bTR \bTD \getspr{2} \eTD \bTD \getspr{5} \eTD \bTD \getspr{A[2] * B[2]} \eTD \eTR \bTR \bTD \getspr{3} \eTD \bTD \getspr{4} \eTD \bTD \getspr{A[3] * B[3]} \eTD \eTR \eTABLE \startspreadsheettable \startrow \startcell "Amount" \stopcell \startcell "Single" \stopcell \startcell "Sum" \stopcell \stoprow \startrow \startcell 2 \stopcell \startcell 5 \stopcell \startcell A[2] * B[2] \stopcell \stoprow \startrow \startcell 3 \stopcell \startcell 4 \stopcell \startcell A[3] * B[3] \stopcell \stoprow \stopspreadsheettable \stoptext Wolfgang