Sales invoice for customer prevous balance

i want to add customer previous balance in ths sale invoice and then total balance can someone give me the html codes for this

There was a code posted by someone for that. But those features are obsolete as extensions and custom themes were needed for that. Btw your other options are a Custom field in which you can enter the previous balance manually or provide statement with invoice.

For Cash or Accrual basis of accounting

What is your point, @stec1921? It does not seem to be relevant to this topic.

Hi good pm. Would a previous balance not be shown in the AR/AP report, if you was on an Accrual basis of accounting. However if you was working on Cash basis of accounting, (As with Cash is Cash so you should only record what hits the bank) then you would need to record under and over payments to understand a previous balance. A Cr as an Overpayment balance or a -Cr as an Underpayment balance. So my thought was that the code might need to be different depending on the method of accounting.