How do I make visual basic put a criteria in a query?

A

Allen Browne

Assign it to the SQL property of a query.

For example, if you have a query named Query2:
strSql = "SELECT * FROM Table1;"
Currentdb.QueryDefs("Query2").SQL = strSql

--
Allen Browne - Microsoft MVP. Perth, Western Australia

Reply to group, rather than allenbrowne at mvps dot org.

"Powering Queries with VB" <Powering Queries with
(e-mail address removed)> asked the question in the subject in message
news:[email protected]...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top