Creating Custom Error Reports

S

StuJol

i have an Access2003 database with approx 2000 vb function. each function
returns its own custom error code along with the err.number and
err.description.

Each time an error occurrs a msgbox is displayed indicating the error msg to
the user.

im trying to find a way to send an automated email that contains the error
msg without having to edit all my functions.

my questions are

1) is thier a way to automate a screen dump (eg press Ctrl+print screen) and
then place it as an attachment to an email?
2) can i create a custom button on a msgbox that sends an email?
3) is their any vb code that grabs the text message from an active msgbox?
 
T

Tom Wickerath

Hi StuJol,
im trying to find a way to send an automated email that contains the error
msg without having to edit all my functions.

I suggest, instead, that you write the details of the error (NTUserID,
ComputerName, date stamp, err.number, err.description, object name, procedure
name, etc.) to a table. This way, you'll be in a better postion to analyzer
the results, and go after the most frequent errors or perhaps alert you to a
particular user who is generating lots of errors, without getting potentially
inundated with separate e-mail messages.
1) is thier a way to automate a screen dump (eg press Ctrl+print screen) and
then place it as an attachment to an email?

Possibly, but I don't know. However, a screen dump is likely not going to
tell you much more than just logging the various details to a table.
2) can i create a custom button on a msgbox that sends an email?

No. You can create a custom button on a form, and invoke your form to
display the same information that the message box currently displays, but you
cannot create a custom button on a msgbox.
3) is their any vb code that grabs the text message from an active msgbox?

Just write the err.number & err.description to a table, instead of
attempting to grab the same text from an active msgbox.


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________
 

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