I'm getting Data type mismatch in criteria expression.
SELECT tblMain.LastBatch
FROM tblMain
WHERE (((tblMain.LastBatch)>CLng("getStoreddate")));
getStoreddate is a UDF that returns a date. But Access puts quotes around it, and I think that's the problem.
LastBatch is a Long number field.
How might I get this to work? Thanks.