I don't know what a QBE is.
Coding the On Click event is what you could do - though the wizard will do
the coding for you.
Do you want the info just displayed?
If yes, the easiest way is to create a form (FrmFindEmployee) based on your
Employee table which has just those fields which the user might want to see.
When you've created your text box, use the Properties box on the Other tab
to name it txtFind
Add your button. When the Wizard kicks in, choose Form Operations, Open
Form.
Choose your newly created FrmFindEmployee from the list of forms.
Choose to 'open the form and find Specific Data'
In the left-hand list choose your txtFind box.
In the right hand, choose EmpNo
Does this give the results you wish or have I misunderstood something?
Evi
JBad said:
Hi Evi
Thks for the reply but i cudnt fully get the hang of it. Sorry

. Im a
newbie to Access Programming. Anwyays, here are the details:
EmpNo is a number. I've got a table (for example):
EmpNo as Double
EmpName as Text
DOB as Date
PassportNo as Text
PassportExpDt as Date
Now, I would want the user to enter only the EmpNo in a normal unbound
textbox and upon cliking the "Find Record" button, the snippet should find
that particular record and display the rest of the fields in proper textboxes
or labels (which do u advise?).
For this, should i create a query in the QBE or i can simple write some code
in the OnClick event of the "Find Record" Button?
Thanks a heap...
Evi said:
It is easy. You can do it with help. If you are talking about a record
within your form, then try adding a combo box in Design View. One of the
options which the Wizard will give you (if your form is based on a table
with a Primary Key) is to find a record in your form.
Are you talking about a record in the form's subform, in another form?
When you add a command button to a form, the Wizard gives you several
options and will do much of the work for you including opening a form of
your choice or Running a Query.
Let us know how you want to do this, give the name of the form/query which
you wish to open and say if EmpCode is text or number
Evi
How can i call / run a query from a form?
Ex:
EmpCode: --- [Find Record]
When the user clicks the Find Record button, the query is run which would
most likely retrieve the correct record.
Is there any other easier way to find a record?
Thanks..