Check/Change email settings at run time

delphi package - automated exception handling

Check/Change email settings at run time

Postby DaveHackett » Wed Dec 14, 2016 2:27 pm

It's been awhile since I've used madExcept. I'm now doing support for a large Delphi app and I have an issue from a client where the madExcept process is failing to send in the bug report via email. Simple enough, the client doesn't use smtp email from his laptop and I think that is how the app was configured (I didn't write it).

The app is auto built via Jenkins on one of the corporate Windows 2008 servers. Code changes are handled via GitLab, where uploads into any branch will trigger a new build. I can browse the madExcept folder where the build happens but I don't see where the settings are stored. mad.inc seems to be the only config file in that directory. Where do I go to see/change the settings so I can send him a special build? Or is there a way to change the email settings in the field at run time before the exception happens?

After this, I think I'll recommend to the company to use the web service reporting option, but until then, it would be great if I can help out this user.

Thanks
DaveH
DaveHackett
 
Posts: 2
Joined: Wed Dec 14, 2016 2:13 pm

Re: Check/Change email settings at run time

Postby madshi » Wed Dec 14, 2016 2:39 pm

The madExcept settings are stored in a file named "yourProjectName.mes". If such a file doesn't exist, default settings are used instead. Which is not probable in this case, though, because by default SMTP mailing is not enabled.

You can change all the settings at runtime, if you like. See more details here:

http://help.madshi.net/MESettings.htm

For example, you could do "with MESettings() do begin SmtpServer := '...'; [...] end;".
madshi
Site Admin
 
Posts: 9268
Joined: Sun Mar 21, 2004 5:25 pm

Re: Check/Change email settings at run time

Postby DaveHackett » Wed Dec 14, 2016 2:58 pm

Ah, found the reference in the build...

"C:\Program Files (x86)\madCollection\madExcept\Tools\madExceptPatch.exe" "%WORKSPACE%\NRG\bin\MMSPOS.exe" "%WORKSPACE%\NRG\main\MMSPOS.mes"

So, there is no "HotKey" to invoke MadExcept at run time so the user can change the settings? I sort of remember from long ago that madExcept also kept settings in the registry. Hoping the user could modify the settings and run the app again as is to generate the error.

Thanks for the link. I did read about that before asking the question. Of course, I'd have to build the interface to allow him to change the settings so it doesn't help me with the version already in the field. I do however plan to use those functions to switch the app to a web services upload model from the smtp model.

DaveH
DaveHackett
 
Posts: 2
Joined: Wed Dec 14, 2016 2:13 pm

Re: Check/Change email settings at run time

Postby madshi » Wed Dec 14, 2016 3:02 pm

There is no nadExcept dialog for changing email settings at runtime, there never was. If you need to provide the user with a settings dialog for email settings, you will have to design the dialog yourself, sorry about that.
madshi
Site Admin
 
Posts: 9268
Joined: Sun Mar 21, 2004 5:25 pm


Return to madExcept

Who is online

Users browsing this forum: Google [Bot] and 2 guests