Domanda

I notice that while developing an Android application, sometimes when an uncaught Exception is thrown due to a bug in my app, it doesn't force close the app, but simply resets to the main activity.

What circumstances cause this to happen?

È stato utile?

Soluzione

The exception occurs in a specific activity, which then dies. Focus is then returned to the activity one higher up in you app's activity stack.

If this activity isn't affected by the cause of the exception in the dead activity, it will simply process as normal.

Altri suggerimenti

When there is null pointer exception in the current activity which won't affect the other activities.. Also when few resources not found!!

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top