Calculateing in a form control

  • Thread starter Thread starter Jan Il
  • Start date Start date
J

Jan Il

Hi all - Access 2002 - WinMe

I am creating a form to do date entry, and I want to display a balance in a
control on the form. I want to show a sum of the difference between two
other controls on the form. The name of the form is frmCheckRegister.

What I now have in the Balance control on the form is:

=Sum([Forms]![frmCheckRegister]![txtCheckAmt]-[Forms]![frmCheckRegister]![tx
tDepositAmt])

But, I am getting an #Error in the Balance control.

I would truly appreciate any suggestions on where I have made the mistake in
this calculation.

Best regards,
Jan :)
 
Jan said:
Hi all - Access 2002 - WinMe

I am creating a form to do date entry, and I want to display a balance in a
control on the form. I want to show a sum of the difference between two
other controls on the form. The name of the form is frmCheckRegister.

What I now have in the Balance control on the form is:

=Sum([Forms]![frmCheckRegister]![txtCheckAmt]-[Forms]![frmCheckRegister]![tx
tDepositAmt])

But, I am getting an #Error in the Balance control.

The aggrgate functions do not operate on controls, they only
work with fields in the record sdource query. If the
txtCheckAmt text box is bound to the CheckAmt field and
similar for the DepositAmt field, then the balance text box
could use the expression: =Sum(CheckAmt - DepositAmt)
 
Back
Top