> Employees is a table, yes an sure the openrecordset statement isn't
> the problem is in the select or something related to the table, EmpID
> in the table is text, is that a problem?
Yep, It means you have to put quotes around the value...
vSql = "Select employees.EmpID, employees.FirstName " _
& "from employees where Employees.EmpID = '" & Me.EmpID & "'"

Signature
Rick Brandt, Microsoft Access MVP
Email (as appropriate) to...
RBrandt at Hunter dot com
Orlando - 18 Mar 2007 04:16 GMT
Thanks Rick It works perfectly, like magic.
I appreciate your help.
> > Employees is a table, yes an sure the openrecordset statement isn't
> > the problem is in the select or something related to the table, EmpID
[quoted text clipped - 4 lines]
> vSql = "Select employees.EmpID, employees.FirstName " _
> & "from employees where Employees.EmpID = '" & Me.EmpID & "'"