Can anyone tell me what is wrong with this statement? I kept getting TYPE MISMATCH error.
TotalQty = (DSum("[QtyOrdered]", "Load Query", "[ProductCode] = '" & TPC & "'" And "[CDueDate] = #" & PCDate & "#"))
If I put the criterias seperately then the statement works, but if I use the AND to use the criterias together, then I get the TYPE MISMATCH.
Thanks,
TD
TotalQty = (DSum("[QtyOrdered]", "Load Query", "[ProductCode] = '" & TPC & "'" And "[CDueDate] = #" & PCDate & "#"))
If I put the criterias seperately then the statement works, but if I use the AND to use the criterias together, then I get the TYPE MISMATCH.
Thanks,
TD