Solved

basic Error Handling question

Posted on 2011-02-26
2
205 Views
Last Modified: 2013-11-05
If I use ON ERROR GOTO <some label> in a subrountine, and I have an ON ERROR GOTO 0 at the end of this subroutine, this sub's ON ERROR GOTO 0 does not turn off error handling for the code that called this sub. Right?
0
Comment
Question by:lee88
2 Comments
 
LVL 69

Accepted Solution

by:
Éric Moreau earned 500 total points
Comment Utility
on error ... are local to the method that contains them (they have no effect on the caller).

on top of that, they are only effective starting at the line they are executed.

there is no need to have "on error goto 0" on the last line of a method
0
 

Author Closing Comment

by:lee88
Comment Utility
Thanks!
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
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 Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

772 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

11 Experts available now in Live!

Get 1:1 Help Now