DSum in a continuous form control where previous record is used to make calculation on current record
Posted on 2005-04-02
Access 97: I have a form that is tied to one table. The form basically is a "check register" and the table holds all checks and deposits in my checking account (this table is called CheckWriter. The default view of the form is Continuous Forms. This application was developed by someone else some time ago and I'm trying to change it. The form contains the fields check number, check date, payee, check amount, deposit amount, and then running balance. The form's data is basically the entire CheckWriter table. The running balance control on the form is a DSum function adding the Deposit Amount and subtracting the CHeck Amount, the criteria also uses the TransID field in the tabel. For various reasons I don't want to use the TransID field anymore. SO, my question is: How can I do a running balance field, using the DSum function, but have it include the record above the record it's currently calculating, you know, like a real check register. So I can do something like: previous record running balance - check amount + deposit amount.