Setting up a form to use a table's info?

  • Thread starter Thread starter WhatAboutBob?
  • Start date Start date
W

WhatAboutBob?

Hello,

I would like to get this done as simply as possible for now if it can
be done. Okay. so what if you want to create a form from a table, and
have info like:

Name.field
Address.field
Address 2.field
Phone.field
Fax.field
Email.field

and that is all stored in the table, and you want to create a form
whereby all you do is type in the name, and the rest of the fields
populate themselves based on the name in the Name.Field? Does this
require you to bind text boxes?

So on the form, in the Name box you type in:
Name: Bob Smith

and then all the other fields associated with that record pop into the
form... what is the easiest, and simplest way to go about that?

Thank you
 
The easy way is to simply build a form with all of the fields on it.

You can / should give the form wizard a try. This will give you a bound form
that can view, and edit data.

To add the ability to "display"/search to a particular name, I would suggest
then using the wizard to add a combo box.

Choose the option "I want to find a record based on......"

Place this combo box at the top (or even in the forms header). If you build
this combo box with he wizard, then when you type in a name (or even drop
down the combo box to view names), and then when you choose (or type) in a
name..the form will display/jump to that record....

Thus, you don't need to write any code...but just use the wizards....
 
Albert said:
The easy way is to simply build a form with all of the fields on it.

You can / should give the form wizard a try. This will give you a bound form
that can view, and edit data.

To add the ability to "display"/search to a particular name, I would suggest
then using the wizard to add a combo box.

Choose the option "I want to find a record based on......"

Place this combo box at the top (or even in the forms header). If you build
this combo box with he wizard, then when you type in a name (or even drop
down the combo box to view names), and then when you choose (or type) in a
name..the form will display/jump to that record....

Thus, you don't need to write any code...but just use the wizards....

--
Albert D. Kallal (Access MVP)
Edmonton, Alberta Canada
(e-mail address removed)
http://www.members.shaw.ca/AlbertKallal


Thank you Albert! That worked beautifully :)

Okay, now for question 2! What if I want to add more than one table to
the form, because I want to seperate the data rather than having a HUGE
table.

So say, I have those first fields that I mentioned Name, Address, etc.
Now Say that I want to create another bunch of fields on the form that
would be related to another table. Say something like a table with
records about years and earnings... is this where you start to link
tables?

Thank you

How would I go about adding those on there... through the wizard again?
 
WhatAboutBob? said:
Thank you Albert! That worked beautifully :)

Okay, now for question 2! What if I want to add more than one table to
the form, because I want to seperate the data rather than having a HUGE
table.

So say, I have those first fields that I mentioned Name, Address, etc.
Now Say that I want to create another bunch of fields on the form that
would be related to another table. Say something like a table with
records about years and earnings... is this where you start to link
tables?

Thank you

How would I go about adding those on there... through the wizard again?

Okay, that is working perfectly! Now I have my main table with all that
info, and I create a new table, so that I can transfer the information
over that I need just by typing the name of the school in, and then
updating the other fields I have with the manual input later on when
the information comes in.

How do I make it so that the information is transfered over from one
table to another just by typing in the name that I want?

Thank you
 
Example

I type in the Name, and all the fields with the name pop up into this
new table through the way you mentioned.

So how do I store them into this new table? My understanding is that I
am looking at the record from another table, but how do I store that
info into this new table? to add to a new record with other fields that
need to be manually input?
 
Thank you Albert! That worked beautifully :)
Okay, now for question 2! What if I want to add more than one table to
the form, because I want to seperate the data rather than having a HUGE
table.

So say, I have those first fields that I mentioned Name, Address, etc.
Now Say that I want to create another bunch of fields on the form that
would be related to another table. Say something like a table with
records about years and earnings... is this where you start to link
tables?

Great example. I would build the earnings table. There would be one field in
the earnings table that relates back to the customers table (this would a
long number field..and NOT a number field in the earnings table)..

You would build the table, add the relationship (customers to earnings
table -- remember, which way you draw the relational join line is
important).

Now once you have the above done, bring up your form in design mode, and add
what we call a sub-form from the tool box. This will setup a what we call a
sub-form, and this enables you to have a form with more then one table, and
further maintains that one to "many" structure you designed in the tables.

For the above sub-form, you likely will use a datasheet, or continues form.

You can try the above. I talk about using sub-forms here:

http://www.members.shaw.ca/AlbertKallal/Articles/fog0000000005.html

And, I have some ideas, and screen shots of sub-forms, and continues forms
here...they will also give you some good ideas to see what can be done:

http://www.members.shaw.ca/AlbertKallal/Articles/Grid.htm
 
How do I make it so that the information is transfered over from one
table to another just by typing in the name that I want?

You don't transfer the information. You have a relational database at your
fingertips!!!

You would ONLY need to store the ID of the customer in that new form/table.
Read my article on sub-forms, and note how in that example I used a sub-form
to display (note NOT COPY....BUT DISPLAY!!!) the customer information.

So, you don't transfer the information, you use the relational concepts of
database systems to point, or attach to the customer..but you NEVER actually
copy the data, and if you design it right...you don't have to !!! (so, it is
much less work!!).
 
Type-o

this would a
long number field..and NOT a number field in the earnings table)..

Should read

this would a
long number field..and NOT a AUTO number field in the earnings table)..
 

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

Back
Top