J
Jeff Hunt
I am trying to write a function that will produce a detailed message box
whenever an error occurs. Right now, my error handlers have all been set to
call the following function:
Public Sub generalErrorMsg()
MsgBox Err.Description & " (Error #" & Err.Number & ")" & vbCrLf & vbCrLf & _
"Please file a ticket and include this error number and description.", ,
"Error"
End Sub
Because these will be called from different procedures and different forms,
possibly even from different functions, I would like to determine what is the
name of the sub or function that called generalErrorMsg(). I know I could
change the function to accept a string and just pass the name of the calling
sub to the function when the function is called, but I would like to not have
to include that in every error handler. Anyone know of a way to do this?
whenever an error occurs. Right now, my error handlers have all been set to
call the following function:
Public Sub generalErrorMsg()
MsgBox Err.Description & " (Error #" & Err.Number & ")" & vbCrLf & vbCrLf & _
"Please file a ticket and include this error number and description.", ,
"Error"
End Sub
Because these will be called from different procedures and different forms,
possibly even from different functions, I would like to determine what is the
name of the sub or function that called generalErrorMsg(). I know I could
change the function to accept a string and just pass the name of the calling
sub to the function when the function is called, but I would like to not have
to include that in every error handler. Anyone know of a way to do this?