Sometimes it happens that the program is closed (due to some fatal escape). Is it possible to catch this moment in the program? I want that if a user has such an event, it will automatically be transferred to my tracker (the API for this has been used for a long time).
4 answers
You can install handlers for Android Developers threads . That is, in fact, it can also be assigned to the main application flow. And just do recommend using a third-party service Bugsense - it allows you to catch errors in applications that are already placed in the market, collects statistics and statistics for these errors.
There is a solution to the problem. And having ACRA
Such a problem is often solved with try and catch. You can put a report in catch. In general, it is still necessary for the user to ask if he wants to send a report. And provide no internet connection at the time of the crash.
IMHO I use Critercism in general, no complaints. in contrast to an acre, it unnecessarily cares about the overflow of GoogleDock (if this has not yet been fixed) and indeed there is no usability at all. Crashlitycs - used but except for a beautiful design and a galim plug-in for eclips did not see anything.
but it is important to bear in mind that not one of the above solutions will not save you if an error occurred in the native code . then it is important to correctly catch this mistake and do something))).