D
Dave
I'm trying to implement a global error processing system
for my MS Access 2002 application. It would be much more
convenient for me if there was some way to identify the
name of the function that called the currently executing
function.
Example:
public sub main()
my_error_obj.assertCondition <condition check>
end 'main
Class my_error_obj
public sub assertCondition arg1
if <arg1 fails> then
err.raise number:=myErrNumber, _
source:=<calling procedure name> 'in
this case, it should be "main"
end if
end sub
Currently, I'm passing the calling sub name as an
argument, but I'm not satisfied with this solution. There
must be a way to identify the function that called the
current function (Call Stack does it) but I'll be damned
if I can figure out how to do it. Any ideas?
Thanks,
Dave
for my MS Access 2002 application. It would be much more
convenient for me if there was some way to identify the
name of the function that called the currently executing
function.
Example:
public sub main()
my_error_obj.assertCondition <condition check>
end 'main
Class my_error_obj
public sub assertCondition arg1
if <arg1 fails> then
err.raise number:=myErrNumber, _
source:=<calling procedure name> 'in
this case, it should be "main"
end if
end sub
Currently, I'm passing the calling sub name as an
argument, but I'm not satisfied with this solution. There
must be a way to identify the function that called the
current function (Call Stack does it) but I'll be damned
if I can figure out how to do it. Any ideas?
Thanks,
Dave