I've looked and looked but cannot seem to figure out what anyone is saying regarding QueryDef object. So perhaps if I explain what I am trying to do there may be a simpler solution.
I have a list of perhaps 1000 names. I want to select the first 100 or so and send them an email which I will call SalesLetter1. Then I want to select the next 100 and send them SalesLetter1 while I send the first 100 SalesLetter2. And so on. I created a table for the various sales letters, 1 through 10.
As things progress I may want to change the number of names to be selected at one time due to changes in the number of entries in the list. This is what I need. Don't want the user to go and modify the SQL statement.
I've got a second part to all this, but it predicates on solving this first.