For each calculation you will need to use the GetSummary function in order to pull the total through.
Alternatively you could create a calculation in your Invoices table to add up your InvLines total.
Something like InvoiceTotal - Sum ( InvLines::Total )
Then you could create a number field called VAT which auto enters 20. (Probably best creating a separate table for tax rate mind you)
Then finally InvoiceTotalPlusVAT - InvoiceTotal + InvoiceTotal * VAT / 100.
In my database Tax is stored as a whole number like 20 instead of 0.20 so that's why I am dividing the sum by 100.
I didn't realise I can just create calculated fields in the table and add them to my "Trailing Grand Summary" in the report.
Thanks for the help.
Yes, I agree. That is a better method.