Error Message and not sure why Please help

  • Thread starter Thread starter Curtis
  • Start date Start date
C

Curtis

Hi everyone
I got a form set up that is supposed to bring in to values from a table
(TABLE A) and based on user entered information into the same form I got to
do some simple math and store the data in another table (TABLE B). The
problem is that when I link my two fields to TABLE A before anything else is
entered I get this error (#NAME?) showing up in the text box part of the
linked field when I change from design view. It happens for both of my
linked fields. Can someone please advise as what to do

Thanks Curtis
 
Hi everyone
I got a form set up that is supposed to bring in to values from a table
(TABLE A) and based on user entered information into the same form I got to
do some simple math and store the data in another table (TABLE B). The
problem is that when I link my two fields to TABLE A before anything else is
entered I get this error (#NAME?) showing up in the text box part of the
linked field when I change from design view. It happens for both of my
linked fields. Can someone please advise as what to do

Thanks Curtis

What's the Control Source of the form textbox? And what's the
Recordsource of the form?

#NAME? means that Access doesn't recognize the fieldname as being a
field within the Form's recordsource query.

Do note that it's almost never appropriate to store calculated values
in a Table. Storing derived data such as this in your table
accomplishes three things: it wastes disk space; it wastes time
(almost any calculation will be MUCH faster than a disk fetch); and
most importantly, it risks data corruption. If one of the
underlying fields is subsequently edited, you will have data
in your table WHICH IS WRONG, and no automatic way to detect
that fact.

Just redo the calculation whenever you need it, either as a
calculated field in a Query or just as you're now doing it -
in the control source of a Form or a Report textbox.

John W. Vinson[MVP]
 
The thing is I need to know if I can have 2 differnet textboxes on a form
with differnet tables as there control source
 
The thing is I need to know if I can have 2 differnet textboxes on a form
with differnet tables as there control source
'
Not directly. You may be able to base the Form on a Query joining the
two tables; if you're just looking up a value from a table based on a
value on the current record, you can use a Combo Box or use

=DLookUp("[fieldname]", "[tablename]", "[IDfield] = " & [IDfield])

as the Control Source of the textbox.

John W. Vinson[MVP]
 
Back
Top