On Jun 9, 12:02 pm, skink <[email protected]> wrote: > On 9 Cze, 16:49, android app <[email protected]> wrote: > > So this function will provide the code a chance to handle the > > exception (e.g., POST it to a Web service) before the user click > > "Force Close" and kill the app? > > user wont see any dialog as you handled your exception.
It'd probably be wise to grab the previous handler with Thread.getDefaultUncaughtExceptionHandler() and pass control to it when you're done. That way the system behaves as expected. You can see the framework's implementation in frameworks/base/core/ java/com/android/internal/os/RuntimeInit.java . Note especially the crash() function, in which every non-trivial operation is wrapped in a try/catch block. If your catch-all exception handler throws an exception, nobody will be around to catch it, and the thread will just quietly exit. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

