S
Simon Morley
Afternoon All,
I have 20 odd forms, with lord only knows how many procedures, and I'm
trying to write a 'one-function-does-all' error handling procedure. What
I'm planning to do is have a popup message that displays the details of the
error whilst logging those details in a table somewhere and then simply kill
the procedure when the error has not been handled specifically.
There are two bits of info however that I can't find: firstly, I'd like to
be able to record the procedure name that caused the error, e.g.
Retrieve_Click, and the line number on which the error was caused (so when a
user reports an error, I can immediately identify what caused it).
Also, I am planning on cut 'n pasting the error code I write into each
procedure however I'd ideally like to write a proc that would override the
standard Debug/End dialog that VBA uses with my user friendly message box (I
don't want the user to be able to do anything other than report the error
and kill the proc that caused it). I would then need the full proc name,
i.e. Forms!frmMain.Retrieve_Click for my log to be of any use.
Any and all ideas on the above gratefully received.
Simon
I have 20 odd forms, with lord only knows how many procedures, and I'm
trying to write a 'one-function-does-all' error handling procedure. What
I'm planning to do is have a popup message that displays the details of the
error whilst logging those details in a table somewhere and then simply kill
the procedure when the error has not been handled specifically.
There are two bits of info however that I can't find: firstly, I'd like to
be able to record the procedure name that caused the error, e.g.
Retrieve_Click, and the line number on which the error was caused (so when a
user reports an error, I can immediately identify what caused it).
Also, I am planning on cut 'n pasting the error code I write into each
procedure however I'd ideally like to write a proc that would override the
standard Debug/End dialog that VBA uses with my user friendly message box (I
don't want the user to be able to do anything other than report the error
and kill the proc that caused it). I would then need the full proc name,
i.e. Forms!frmMain.Retrieve_Click for my log to be of any use.
Any and all ideas on the above gratefully received.
Simon