Return the Module Location & Sub Procedure Name on Error
- From: RyanH <RyanH@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 14 Oct 2008 11:03:00 -0700
How can I return the Module Location and Sub Procedure of an error when an
error occurs?
Public Sub ProcedureName()
On Error GoTo ErrorHandler
' my code here
Exit Sub
'********************************
ErrorHandler:
Call ErrorHandler(ModuleName, ProcedureName, Err.Number, Err.Description)
End Sub
Public Sub ErrorHandler(ModuleName As String, ProcedureName As String,
ErrNumber As Integer, Description As String)
' show a msgbox with error information
End Sub
--
Cheers,
Ryan
.
- Follow-Ups:
- Re: Return the Module Location & Sub Procedure Name on Error
- From: Chip Pearson
- Re: Return the Module Location & Sub Procedure Name on Error
- Prev by Date: Index/match between workbooks problem
- Next by Date: Most efficient way to loop through a folder and find all the XLS f
- Previous by thread: Index/match between workbooks problem
- Next by thread: Re: Return the Module Location & Sub Procedure Name on Error
- Index(es):
Relevant Pages
|