Hello
My form based procedures are in the format:
Within the Error section is there any straightforward way to refer to the current procedure name so that I don't have to keep changing it as I copy it around [Me.Procedure.Name sort of thing].
... or is there a better way to do this. I want to know the procedure name when an error occurs.
Thanks
My form based procedures are in the format:
Code:
Private Sub ProcedureName()
On Error GoTo ErrorSection
……
Exit Sub
ErrorSection:
MsgBox "Error occured in Form: " & Me.Form.Name & vbCrLf & _
"Routine: ProcedureName" & vbCrLf & _
"Error Code: " & Err.Number & vbCrLf & _
"Description: " & Err.Description
Resume Next
End Sub
Within the Error section is there any straightforward way to refer to the current procedure name so that I don't have to keep changing it as I copy it around [Me.Procedure.Name sort of thing].
... or is there a better way to do this. I want to know the procedure name when an error occurs.
Thanks