How do I get my Access Database Form to Automatically fill in inf.

G

Guest

The company I work for Owns & Manages several thousand sq.ft. of office
space. All of the maintenance work goes through our main office. I am
trying to create a database that will house all the information for each
tenant as well as all the maintenence orders we receive for each building. I
do all of the paper work by hand at the moment and would like to be able to
create a form that I can use on the computer. I would like to be able to
enter the TenantID into this form and the Tenant's information automatically
fill in the corresponding fields. I would like to do the same with the
employee information as well. How do I go about doing this?
 
S

SirPoonga

Using the On Update event for where you enter the Tenant ID (I assume
this will be a dropdown list that is populated on form load) you will
requery the controls that display the tenant info.
 
S

SirPoonga

Actually, it might be the on change event you need to work with. I get
those two confused as in most situations they will work either way.

Someone will have to chime in which is best for this situation.
 
J

John Vinson

Actually, it might be the on change event you need to work with. I get
those two confused as in most situations they will work either way.

Someone will have to chime in which is best for this situation.

The Change event isn't best for this purpose: it fires *at every
keystroke*, that is, every time the content of the control is changed.
The AfterUpdate event is more appropriate in that it runs when the
user has selected a value.

John W. Vinson[MVP]
 
J

John Vinson

The company I work for Owns & Manages several thousand sq.ft. of office
space. All of the maintenance work goes through our main office. I am
trying to create a database that will house all the information for each
tenant as well as all the maintenence orders we receive for each building. I
do all of the paper work by hand at the moment and would like to be able to
create a form that I can use on the computer. I would like to be able to
enter the TenantID into this form and the Tenant's information automatically
fill in the corresponding fields. I would like to do the same with the
employee information as well. How do I go about doing this?

If you're trying to copy the tenent information from the tenent table
into some other table... DON'T. Storing data redundantly is a Very Bad
Idea and is neither necessary nor appropriate!

If you have a Tenent table (or an Employee table) you can easily
*display* the information on a form; for instance, you could have a
Combo Box on the form, created by the toolbox combo wizard, which
would allow you to select a tenent (by name or by ID, whichever is
more convenient for you) and move the "window" of the form to that
tenent's record. Is that what you have in mind?

John W. Vinson[MVP]
 

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

Top