Integration instructions

  1. Download our SDK ExceptionHandler.jar
  2. Put it to libs directory and add to your project classpath.
  3. Add the following permission to your AndroidManifest.xml if it's not already there:

    <uses-permission android:name="android.permission.INTERNET"/>
  4. Register the unhandled exception handler

    ErrorAgent.register(context, PROJECT_ID);
    The best place to do it is in your Application onCreate() method like that:

    import com.dynamixsoftware.ErrorAgent;
    
    public class MyApplication extends Application {
        @Override
        public void onCreate(){
            ErrorAgent.register(this, PROJECT_ID);
        }
    }
    
    "PROJECT_ID" is the unique id of your project.
  5. That's all. You can publish your app and enjoy the crashes.
  6. In more advanced scenarios you may want to report exceptions that are actually handled. You can do it this way:

    try{
        //some code here that may throw exception
    }catch(Throwable th){
        th.printStackTrace();
        ErrorAgent.reportError(th, null);
    }