Getting Error using Dlookup

  • Thread starter Thread starter Van T. Dinh
  • Start date Start date
V

Van T. Dinh

You need to delimit the Test value "jefsav".

Try:

=DLookUp("Name", "employees", "[Login] = 'jefsav'")

HTH
Van T. Dinh
MVP (Access)
 
=DLookUp("Name", "employees", "[Login] = '" & _
loginname & "'")

HTH
Van T. Dinh
MVP (Access)
 
Ahh thank you very much!!!! That did it. I just had the
syntax a bit fubar'd. I will make a note of this for
next time. I should have know it was something simple
like this.

Regards,
Jeff
-----Original Message-----
=DLookUp("Name", "employees", "[Login] = '" & _
loginname & "'")

HTH
Van T. Dinh
MVP (Access)



-----Original Message-----
Ah coolies that worked. Now how about if I want to
replace "jefsav" with a variable that I have defined as a
string? I tried this:

=DLookUp("Name", "employees", "[Login] = " & loginname)

This only returns a NULL

and also

=DLookUp("Name", "employees", "[Login] = " & 'loginname')

This gives me the same canceled opperation error as
before.

Thanks for all the help!!!
Jeff

.
 
Back
Top