Ok, I understood that if you put your label at the end of the sub with an
exit sub just before this label, it will only be executed if the error goto
intruction say to go there. The only problem I seem to have is that if I
click cancel or write text in my inputbox, it seems to continue without using
my error handler. Strange.
Werner
Quote:
On Error GoTo IndexError
[...] 'code I just skipped in this quote
Exit Sub 'if no errors exit procedure
IndexError:
MsgBox "Dead end!"
End
Resume
End Sub
--
Message posted via
http://www.officekb.com