I have created a set of queries and macros which "transform" a mother database into different tables. My problem is that I want to know how I can change a query into a module which will be commanded by a macro.
I need to do this because my database treatment will be automatical, and when I put my query inside a macro, access asks me If I want to add the lines to the tables and so on.
I want the user to be able to populate a table on a single click, therefore I need to point the use of a button from the form on a macro based on a module and not on queries.
The queries I use are quite simple, they use small function based on Instr function, or the count function itself...
Can someone tell me how to write a code line which would perform the same task as the query? After that I'll bind the action of the code and the macro.
if it is a select (display data ) query - yes it will show the data
If it is an action query (make table, update delete) you will not see the warnings that it is running due to the docmd.setwarnings false
the docmd.openquery "queryName" will run the query withour\t having to place the literal sql statement in the code or macro