Update table from unbound textbox

Fabian1675

Registered User.
Local time
Today, 02:42
Joined
May 5, 2011
Messages
23
Hello everyone;
I got textbox1 in a form that is bound to a control source called NumberOfEntries what ever value the user inputs into textbox1 it gets recorded into the table. What I did is change the control source to the textbox1 so the user no longer need to manually input the value; it now automatically enters the value into textbox1. The problem that I now face is the value in textbox1 no longer gets recorded into the table. How do I go about getting the value from textbox1 to record into the table just like how it was before I changed the control source.

Thanks
 
What did you put in CONTROL SOURCE ?
Put it in VBA, and link this field
with the field in the table. (control source).
If you don't know, send a short example
of your MDB, (access2000 or 2002-2003).
 
What did you put in CONTROL SOURCE ?
Put it in VBA, and link this field
with the field in the table. (control source).
If you don't know, send a short example
of your MDB, (access2000 or 2002-2003).

Hi thanks for the reply. I created a query that filter's out certain criteria base on the user input. I used that query as the new control source for textbox1 it looks like this: =DSum("UserInputValue","QueryFilter")

The UserInputValue is a field on the QueryFilter. So whatever value happens to be in UserInputValue is what will be displayed on textbox1 and that value which is being displayed on textbox1 is what I would like to be recorded to the table just like how it was before. I hope I explain that right. Thanks
 
Try this, in Sub Form_BeforeUpdate put this code.

Me.[Field name] = DSum("[UserInputValue]","QueryFilter")
and in Control source link this field with field in the table.
 
Try this, in Sub Form_BeforeUpdate put this code.

Me.[Field name] = DSum("[UserInputValue]","QueryFilter")
and in Control source link this field with field in the table.

Hi,

I'm not sure if I quite follow:

Me.[Field name] =? is this the field name from the table? or from the query I built?
 

Users who are viewing this thread

Back
Top Bottom