A Form for searching information

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

Guest

Sorry this may be a very stupid questions to all of you...

I have a form based on a single table (say, tblStudent) with a key field,
say, StudentID.

I want to design a form which on entering an ID into the StudentID control,
the remaining information from the tblStudent will be populated into a form
automatically. How can I do this? Do I need to use macros? Thanks for your
advice.
 
Fred said:
Sorry this may be a very stupid questions to all of you...

I have a form based on a single table (say, tblStudent) with a key field,
say, StudentID.

I want to design a form which on entering an ID into the StudentID
control,
the remaining information from the tblStudent will be populated into a
form
automatically. How can I do this? Do I need to use macros? Thanks for your
advice.

The simplest way would be to use Filter By Form. First create the form based
on tblStudent. Open the form, and then click on Filter By Form in the
toolbar. Enter the ID into the StudentID field, then click Apply Filter. The
associated record should then be displayed on the form. Be sure to remove
the filter when you're finished.

Carl Rapson
 
use the combo box wizard. It will build a combo box that does exactly as you
ask.....
 
If you set up a combo box for Student Id (based off the tblStudent) with all
of the fields needed in the combo box. The fields could have a width of zero
if you did not want them to show.

On the After Update event of the combo box put:

Address1 = Me.StudentID.Column(1)
Address1 = Me.StudentID.Column(2)
City = Me.StudentID.Column(3)
etc...

The column number starts with zero so column 1 in the example is actually
the 2nd column.

Hope this helps.
Jackie
 
Fred said:
Sorry this may be a very stupid questions to all of you...

I have a form based on a single table (say, tblStudent) with a key field,
say, StudentID.

I want to design a form which on entering an ID into the StudentID control,
the remaining information from the tblStudent will be populated into a form
automatically. How can I do this? Do I need to use macros? Thanks for your
advice.
 
Back
Top