error handling

Posted on 2005-05-17
Last Modified: 2010-05-01
Hello Guys,
                 I need some explanation on how error handling works. In my code I encountered a problem that arises from the fact that the error handler that I use works only once, the first time an error occurs. Because the error happens in a loop I need the error to be handled multiple times. How do I realize that?

Thank you,
Question by:Autofreak
    LVL 85

    Accepted Solution

    When an error is trapped, error trapping is actually turned off.  You must use a Resume statement to turn it back on.  If you return to your loop via a Goto statement then Error trapping is not turned back on and you will get the systems you have described above.

    Author Comment


    Featured Post

    6 Surprising Benefits of Threat Intelligence

    All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

    Join & Write a Comment

    Article by: Martin
    Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
    I was working on a PowerPoint add-in the other day and a client asked me "can you implement a feature which processes a chart when it's pasted into a slide from another deck?". It got me wondering how to hook into built-in ribbon events in Office.
    As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
    Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…

    746 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

    Need Help in Real-Time?

    Connect with top rated Experts

    19 Experts available now in Live!

    Get 1:1 Help Now