View Full Version : Calculated Control in Forms


srajesh
09-13-2007, 09:38 PM
I have a form based on a Table for data entry. I converted one of the fields into a calculated control. But the field in the table does not get updated with this value.
How do i bind the control to the field in the table.

boblarson
09-13-2007, 09:51 PM
Okay, here's a couple of things for you -

1. For a normalized database, you should not store calculated values as you can calculate them at any time in a query or control.

2. That being said (and I STRONGLY suggest against storing calculated values), the way you would do it is to put a hidden textbox on your form that is bound to the field in the table. In the After Update event of the Calculated control, put
Me.YourHiddenTextBoxNameHere = Me.YourCalculatedControlNameHere