I think I figured it out. The table "tmpLastDate" has to be closed in access for the module to run.
I'm thinking not. Which computer you run it on should not be affected by how it runs with the table open in datasheet view. That and the #Deleted comment is a clue that you're not refreshing the table when you run this and the table was already open. To prove this, open the date table, select all rows and delete. Then run the code while that table is still in view. Then use the Refresh All button on the ribbon (version 2007, yours should be similar or if not found, Ctl+F9) and watch what happens.
Last edited by Micron; 01-24-2017 at 12:17 AM.
Reason: clarification
The more we hear silence, the more we begin to think about our value in this universe.
Paraphrase of Professor Brian Cox.