Save error reports on Windows

Sometimes the application hangs and I would like to see a dump at a time to figure it out. I wrote an application that the user can run to automatically generate a dump that I can look at. However, I cannot get users to forget to launch it when it freezes, no matter what I try. They always end up closing the program that triggers Windows error reporting.

WER will create dumps in the temp directory, but unfortunately they will be deleted as soon as the dialog box opens to send information to Microsoft or not.

Becoming an ISV and getting this information from Microsoft's error reporting servers is one solution. But this is not the one that is realistic at the moment.

I cannot imagine that I am the only one who faced this problem. The software is used by dozens of dozens of employees, so to cover them up and force them to launch the application or not close it in this dialog until some other application is running or so on.

The app runs on Windows Server 2003. Too bad as I know Server 2008 has some LocalDumps settings that will allow me to save them.

Any ideas for how to somehow save these dumps so I can analyze them? The obstacle is the user, in the sense that I accepted their stubbornness and do not expect them to launch any other application or do anything special.

Thanks for any advice!

+1


source to share


1 answer


You can choose an automated solution. I believe you have several options at your disposal to detect if you are hung up.



It is possible to use SendMessageTimeout (also note SMTO_ABORTIFHUNG as one of the fuFlags values) from a separate thread in your application. Once you have determined that the main thread is not responding, you can save the dump file wherever you want. There's also IsHungAppWindow () (user32.dll) available with w2k.

+1


source







All Articles