By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,353 Members | 1,235 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,353 IT Pros & Developers. It's quick & easy.

Can I stop running code by user input ?

P: 4
I have looping code in Access which generates Excel spreadsheets and prints them off. They can run to hundreds and at present, once the code starts to run there is no way it can stop cleanly part way through. For instance, if the wrong printer has been selected. (I know that Ctrl-Break should slam it but doesn't always and anyway that's not too user friendly). So is there any way a user input can work ?
Aug 25 '09 #1
Share this Question
Share on Google+
2 Replies

Expert 2.5K+
P: 2,653
Try to yield execution at certain time using DoEvents() function.
Aug 27 '09 #2

P: 4
Thanks FishVal, that seems to be the right direction although it can be a bit iffy.
Aug 27 '09 #3

Post your reply

Sign in to post your reply or Sign up for a free account.