Save unbound fields to table

beginner_access

Registered User.
Local time
Today, 01:03
Joined
Aug 22, 2011
Messages
21
I have a form with a field that has formula for calculation. However, I am unable to link the field to the table since the control source is my formula.

How can I that field to a table?

Any help and suggestions will be appreciated. Thanks in advance
 
Welcome to the Forum! :)

One would not normally store a calculated value, however there are exceptions. That said, to send that value to your Table you could use an UPDATE query in the After_Update event in the last field to be updated that is used by your calculation OR you can use one in the On_Close event of the Form and then no worries it would automatically do it once Users exit the Form.
 
Hi,
You could also link the field to the table field, and have the After_Update event in the last field to be updated that is used by your calculation update the value of the TextBox using Macro or simple VBA.
But, as Gina above has said, Why Save a calculated field?
in similar cases I have created a query on the table, and linked form to it. the query could have calculated fields, the TextBoxes on the form could be linked to this caued
 
Welcome to the Forum! :)

One would not normally store a calculated value, however there are exceptions. That said, to send that value to your Table you could use an UPDATE query in the After_Update event in the last field to be updated that is used by your calculation OR you can use one in the On_Close event of the Form and then no worries it would automatically do it once Users exit the Form.

Sorry for the late reply and thank you so much for your reply. I tried using
Code:
ME.TXT1 = ME.TXT2
for After update or On change event and it didn't work. Any advice?
 
Hi,
You could also link the field to the table field, and have the After_Update event in the last field to be updated that is used by your calculation update the value of the TextBox using Macro or simple VBA.
But, as Gina above has said, Why Save a calculated field?
in similar cases I have created a query on the table, and linked form to it. the query could have calculated fields, the TextBoxes on the form could be linked to this caued

Thank you so much for your reply as well Marlan. How do I link the field to the table field.

The database was created by someone else initially and the only workaround for me is to create a unbound field - calculated field and I would like to save that calculated field to the table along with other data so that when I export, the calculated field will be exported as well.
 
Thank you so much for your reply as well Marlan. How do I link the field to the table field.

The database was created by someone else initially and the only workaround for me is to create a unbound field - calculated field and I would like to save that calculated field to the table along with other data so that when I export, the calculated field will be exported as well.
Hi,
You can export a query too:
http://msdn.microsoft.com/en-us/library/office/ff192065(v=office.15).aspx
 

Users who are viewing this thread

Back
Top Bottom