-
Hello my gracious colleagues,
I have a small problem with the On Error Goto functionality
in the application I inherited. Heres a snipit of the code:
Private Sub cmdOneRight_Click()
(A whole bunch of code)
On Error GoTo lb_exist
Set parNode = Tree2.Nodes.Item(parKey)
GoTo lb1
lb_exist:
(Some other type of Code)
lbl1:
(Some more code)
end sub
Now the explanation:
When the application gets to the "Set parNode = Tree2.Nodes.Item(parKey)" (parKey = R8) it fails with the following error message:
Run-time error '35601': Element Not found"
and will not goto lb_exist.
Now the questions:
1) Why will VB5 sp3 not got to lb_exist when the error is
encoutered?
2) How would I fix this problem?
Thanks to all who help.
-
errors
Unless you need to see the error you could try to incorperate a On error resume next, but I don't know if that is what will work well for you.
-
Thanks
Boy do I feel DUMB
I found my STUPID pills again and I thought I threw them
out.
Firstly thanks Matt for your suggestion.
The real problem is that the IDE was set to break on ALL
errors. Once I change it to break on unhandled errors
everything now works fine.
TGIT (Thank God Its Thursday) and tomorrow is Friday.