I've been reading about the benefits of using currentdb.execute vs Open query for executing Action Queries....I really like the idea of the "dbFailOnError" rolling back any changes if the action query has errors....
However, I haven't been able to get it to work in my VBA in two separate projects....Here's my code:
qrySalesData is the name of the query...When I run this I get the following error:
Error Number3061, Too Few parameters. Expected 2
I do have two parameters being called from the form this is on (Start and End Dates)
Thanks for any insight...
However, I haven't been able to get it to work in my VBA in two separate projects....Here's my code:
Code:
'Run Query
CurrentDb.Execute "qrySalesData", dbFailOnError
qrySalesData is the name of the query...When I run this I get the following error:
Error Number3061, Too Few parameters. Expected 2
I do have two parameters being called from the form this is on (Start and End Dates)
Thanks for any insight...