How do I determine the module line number in error

G

Guest

I have created a standard error handling module which gets passed details of
the error trapped and allows for a common way of displaying errors to my
users.

However I cannot find any way of determining at run time the line number
within the procedure where the failure occurred.

Is there a way to determine the last line executed, or failed, without
coding in reference points in the code?

Many Thanks
 
D

Douglas J Steele

There's an undocumented Erl property, but it only works if you've applied
line numbers.

If you want to apply line numbers (and you're using Access 2000 or newer),
there's a nifty free add-in at http://www.mztools.com that will add them for
you (plus dozens of other useful things)
 
G

Guest

Doug

Thanks for the feedback - the addin looks very useful and has sorted my
problem out.

Regards
Chris
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top