I'll admit this right off, dlookups bother me. I use them all the time, but they bother me. Sometimes they work fine. This is not one of them. Here goes.
Here's the function as is
Code:
DLookUp("[User_ID]","tblUser"," Left([tblOpenItemComments]![Vendor_Name],1) between [From] and [To]")
I have also tried this way with the same results.
Code:
DLookUp("[User_ID]","tblUser"," Left([Vendor_Name],1) between [From] and [To]")
The expression you entered as a query parameter caused the following error. Microsoft Access cannot name ([tblOpenItemComments]![Vendor_Name] you entered in the expression.
I have it in a SELECT query just for testing, but I will be using to update a field in tblOpenItemComments. Here's the SQL.
Code:
SELECT User_ID,
Vendor_Name,
Left([Vendor_Name],1) AS Initial,
DLookUp("[User_ID]","tblUser"," Left([tblOpenItemComments]![Vendor_Name],1) between [From] and [To]") AS UserID
FROM tblOpenItemComments
WHERE tblOpenItemComments.User_ID Is Null AND tblOpenItemComments.Vendor_Name) Is Not Null
I suspect this is the wrong way of going about this. I even suspect what the problem is, but for the sake of time tell me if this is a dead end or not would be helpful.