Forum Discussion
irina_lukina
14 years agoSuper Contributor
Hi Jyothi,
In this case, I recommend that you use the On Error Resume Next statement:
Function x(a)
If a = 2 then
msgbox "Hi"
else
msgbox "Fail"
err.raise
end if
End Function
Sub a
call x(1)
if x <> 0 then
exit sub
end if
msgbox "Pass"
End Sub
Sub b
call x(2)
msgbox "Pass"
End Sub
Sub Main
On Error Resume Next
call a
On Error Goto 0
call b
End Sub