Running total in balance field of checkbook database

Amateur here needs help with how to create a running total for a “Balance” field in a checkbook database.
Can you point me in correct direction?

Activate your Balance field and use the menu Field > Analyze > Running Total.

Or you write a little procedure:

field Balance

This is a checkbook.
I want the balance to reflect adding credits and subtracting debits, not simply accumulate the numbers in the balance field.

One way is to add the calculation to your procedure:

field Balance
formulafill Credits - Debits

Or you can do that manually by using the menu Field > Morph > Fill With Formula …

Another way is to set up your Credits and Debits fields to do that calculation automatically when you enter values in these fields.

You might want to read the Panorama X Help about “Automatic Field Calculations”.

Just a quick thought. In accounting Assets including “Cash in Bank” are normally Debits. When you write a check it is a Credit to “Cash in Bank”, when you make a deposit it is a Debit to “Cash in Bank”. In order to reflect the positive balance of the checking account the calculation should be:

field Balance
formulafill Debits - Credits

Of course if you write hot checks this will be a negative amount. Hope this helps.

I thought this had fixed it,
But I intermittently get results with 12 digits to right of decimal place.

Any explanation as to why this is happening ?


That’s typical of floating point calculations. The only dollars and cents values that can be represented exactly by a binary number are multiples of 25 cents. Occasionally the discrepancy will be large enough to creep into the last digits displayed. Use an output pattern of #.,## to get the display to round off to the second decimal.

great, running like clockwork now.
Thanks, CM

I can’t find Automatic Field Calculations
how can I do as you suggested set up Credits and Debits fields to do that automatically - your help would be so appreciated

If you open the Help window and type automatic f it will be one of the 3 topics listed. Or you can just click on the link below:

However, based on an email you recently sent in, I think you actually want the topic Automatic Field Code.


Thank you - appreciated