Here is what I use quite successfully...
1. The very first line of code to run should be:
AddHandler Application.ThreadException, AddressOf
modGlobal.OnThreadException
2. In a standard module called modGlobal, add a method called
OnThreadException that looks like this:
Public Sub OnThreadException(byval sender as object, byval t as
System.Threading.ThreadExceptionEventArgs)
dim exp as Exception = t.exception
dim strMsg as string
strMsg = String.Format("We're sorry, an untrapper error occurred.{0}The
error messaged was:{0}{1}",vbcrlf,exp.ToString)
msgbox(strMsg)
End Sub
--
**************************************
Andrés Becerra
Pennsylvania, USA
Email not posted due to email stealing A**H***S that poll newsgroups.
**************************************