How to insert customized info into bug reports

delphi package - automated exception handling
Post Reply
danb64
Posts: 3
Joined: Mon Aug 22, 2005 6:11 pm
Location: Dallas, TX

How to insert customized info into bug reports

Post by danb64 »

Is there a simple way to insert my own custom info into the bug reports? My problem is that I sometimes have problems identifying who sent me the bug report e-mail, and they don't have reply-to addresses on them (and I'm not sure why that is the case). So right now the only way I can tell who sent it to me is to look at their computer name and user name and any other clues I can glean based on the version number and by looking at the screen shot. I realize that in some people might have issues with this sort of thing, but in my case this is an internal application so I think it should be OK.

Thanks in advance,

Dan
madshi
Site Admin
Posts: 10338
Joined: Sun Mar 21, 2004 5:25 pm

Post by madshi »

The reason why the mails don't have a reply-to-address is probably that you're using SMTP mailing. This bypasses any locally installed mail client and sends the mail directly to the internet. madExcept can't guess what the email address of the end user is, so it doesn't add a reply-to-address to the mail in that case. If your program does know this email address, just fill into the "madExcept.MailFrom" string variable at runtime, and the problem will be gone.

madExcept 3.0 (will be released in next Monday) can optionally ask the user for his email address and use that as the reply-to-address.
danb64
Posts: 3
Joined: Mon Aug 22, 2005 6:11 pm
Location: Dallas, TX

Post by danb64 »

Thanks for the speedy reply.

Your suggestions will certainly help. However, even though I do have a field where I can glean the e-mail address, the e-mail address may be left blank in the application. And even if it isn't blank, there's no guarantee that it is correct. So I would like to provide even more information in the bug report, even if the e-mail address is available. I would like to include at least the company name and the user's full name, and the city, state and postal code of the company. This info is already available in the application, and it would be so helpful in identifying exactly who it was that encountered the error condition. Is there a way to do this? If possible I would like to modify the bug report right after it is generated, and before it is saved to the local hard disk, printed, or e-mailed. The user always has the ability to view the bug report, so they will have the choice whether to send that information to us or not.

Thanks again,

Dan
madshi
Site Admin
Posts: 10338
Joined: Sun Mar 21, 2004 5:25 pm

Post by madshi »

You can easily modify the bug report. Just call RegisterExceptionHandler and in your handler change the "var bugReport: string" parameter. That's exactly what you're asking for (before saving/mailing/etc).
danb64
Posts: 3
Joined: Mon Aug 22, 2005 6:11 pm
Location: Dallas, TX

Post by danb64 »

That's what I thought. :-)

Thanks again,

Dan
Post Reply