The program goes to the point in the code with the label and continues executing (presumably, you have defined what to do here to mitigate the error)
ON ERROR GOTO Label
The program will continue ignoring errors until it either can't run at all, you handle the errors, or you disable the resume next option. I often (but not always) use ON ERROR RESUME NEXT to allow the program to continue and then I explicitly check for an error number and handle the error there. For example:
ON ERROR RESUME NEXT
ON ERROR RESUME NEXT X = 5 IF X = "bob" THEN X = "Bob" IF ERR.NUMBER <> 0 THEN 'Handle the error END IF
ON ERROR GOTO 0
Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.
When asked, what has been your best career decision?
Deciding to stick with EE.
Being involved with EE helped me to grow personally and professionally.
An Experts Exchange subscription includes unlimited access to online courses.Get Started
Connect with Certified Experts to gain insight and support on specific technology challenges including:
We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE