command button to run 2 querys

  • Thread starter zaps via AccessMonster.com
  • Start date
Z

zaps via AccessMonster.com

Hi there,
Is it possible to have a command button run more than 1 query? I have 2
querys "qry_CommentType" and "qry_CommentTypeTotal". The "qry_CommentType"
needs to be run before the other one. Right now I have 2 command buttons on
my form to run each query separately. Any great is greatly appreciated!
 
O

OfficeDev18 via AccessMonster.com

Yes, you can have one button do them all, and they'll run synchronously,
which means query 2 will wait for query 1 to finish. it's done all the time.

Sam
 
Z

zaps via AccessMonster.com

Do you know how I can do this? Also, could I have the button run the 2
querys in sequence, and then open up a report?
 
O

OfficeDev18 via AccessMonster.com

DoCmd.OpenQuery "the first query name in quotes",...etc.
DoCmd.OpenQuery "the second query name in quotes",...etc.
DoCmd.OpenReport "your report name in quotes",...etc.

You can see the methods in the help file for details.

Sam
Do you know how I can do this? Also, could I have the button run the 2
querys in sequence, and then open up a report?
Yes, you can have one button do them all, and they'll run synchronously,
which means query 2 will wait for query 1 to finish. it's done all the time.
[quoted text clipped - 6 lines]
 

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