Auto-fill in Access?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello (again),

This may not be an available feature w/ Access, but I thought I'd ask. Does
Access have a means by which to incorporate an Auto-fill in a form? I
maintain a database where each record is rather lengthy and it would be so
helpful if the database was capable of recognizing a person's name (or
company), and if they are already in the database, fill in the remainder of
the information. Is this something anyone could/would walk me through?

Sorry for the novice nature of my questions,
Sean
 
A combo box will limit the possibilities as you type something into it.

Now if the database is normalized properly, you select just the primary key
from the Person table and all that person's information is linked to the
record.
 
The normal approach is to use a combo box.

Have its RowSource be a query that returns all of the fields about that
customer in which you're interested. (You don't need to make them all
visible in the combo box if you don't want to). Then, in the AfterUpdate
event of the combo box, populate the fields on your form from the record
your user selected, using the Column collection of the combo box. For
instance, if the query that's being used as the RowSource has the street
address as its 4th field, the city as the 5th field and the phone number as
the 6th field, you'd do something like:

Me.txtAddress = Me.MyComboBox.Column(3)
Me.txtAddress = Me.MyComboBox.Column(4)
Me.txtPhoneNumber = Me.MyComboBox.Column(5)

(note that the Column collection starts numbering at 0, not 1)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Auto fill 1
auto fill a field 3
Date and Auto Fill 1
Retrieve data from Access database and fill data in form 0
Tracking Auto Expenses 3
Auto fill 4
Auto Fill Fields for Order Entry Detail 2
Auto Fill 2

Back
Top