Dlookup, one more time

  • Thread starter Thread starter Beverly76
  • Start date Start date
B

Beverly76

I know this has been answered before but I can't understand what to do from
prior postings.

I have a data entry form that is linked to a table.
When I type in the NUMBER field, I would like the DESCRIPTION to fill in
automatically on the form. The description is just for viewing. It does not
need to be stored anywhere. A separate table called "DESCRIPTIONS" holds the
item numbers and descriptions and no other fields.

I tried a text box with a DLOOKUP which did not work. I guess I need to do
an AFTER UPDATE on the NUMBER field so that the Description field on the form
is filled in ... I do not want to use combo boxes which is what I have done
in the past.
 
That sounds about right. In the Number field AfterUpdate event, you
should set the Description textbox to the result of your DLookUp using
the Number field as criteria.
 
Yep you are right use the after update event.

Something like: me.textbox=dlookup("description","tablename","Number=" &
me.number)

hth
 
Back
Top