Hi Mark Murphy ,

      I have the default handler, if i not reraise the exception using
Thread.*getDefaultUncaughtExceptionHandler*() am getting ANR  also my Toast
or dialogs are not displayed on the screen.



*

public* *void* uncaughtException(Thread thread, Throwable ex) {

 new Handler().post(new Runnable() {

 public void run() {

 Toast t = Toast.makeText(getApplicationContext(), "*uncaugt* *ex*",

 Toast.LENGTH_LONG);

 t.show();

 }

 });

previousHandler.uncaughtException(thread, ex);

}



On Wed, Nov 2, 2011 at 5:06 PM, Mark Murphy <[email protected]> wrote:

> If you have the default uncaught exception handler, and do not
> re-raise the exception, no error dialogs should appear except your
> own.
>
> On Wed, Nov 2, 2011 at 6:21 AM, Jey <[email protected]> wrote:
> > Hi all,
> >
> >            can we show our custom dialog's when any exception occurs?
> > i can catch the exception with help of UncaughtExceptionHandler but i
> > need to disable error dialogs
> >
> > --
> > 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
> >
>
>
>
> --
> Mark Murphy (a Commons Guy)
> http://commonsware.com | http://github.com/commonsguy
> http://commonsware.com/blog | http://twitter.com/commonsguy
>
> _Android Programming Tutorials_ Version 4.0 Available!
>
> --
> 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

-- 
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

Reply via email to