Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Cannot stop code with tight loop using ctrl-break

Posted on 2008-10-06
4
254 Views
Last Modified: 2013-11-27
I  cannot get code with a tight loop (series of ADODB commands) to stop when I hit ctrl-break unless I put in a DoEvents statement to execute every 100 iterations of the loop. When the code does stop it is always on the DoEvents statement and the CPU is still running at 100% and I cannot step forward from the DoEvents statement, only continue execution with F5. Any ideas on how to be able to stop code in tight loops using ctrl-break and be able to step forward fronm the stopping point?
0
Comment
Question by:SimonKravis
  • 2
4 Comments
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 22655574
are you using a counter ?

try using

if counter=100 then stop
0
 

Author Comment

by:SimonKravis
ID: 22655602
I need the flexibility of using a user-initiated action rather than satisfacyion of a preset condition, which will certainly work.
0
 
LVL 26

Accepted Solution

by:
dannywareham earned 500 total points
ID: 22655623
0
 
LVL 26

Expert Comment

by:dannywareham
ID: 22655874
Glad to help :-)
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In the previous article, Using a Critera Form to Filter Records (http://www.experts-exchange.com/A_6069.html), the form was basically a data container storing user input, which queries and other database objects could read. The form had to remain op…
QuickBooks® has a great invoice interface that we were happy with for a while but that changed in 2001 through no fault of Intuit®. Our industry's unit names are dictated by RUS: the Rural Utilities Services division of USDA. Contracts contain un…
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

789 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question