public class MainActivity extends Activity { private static String[] DEX_FILES = {"dexter.dex"}; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); try { for (String dex : DEX_FILES) Dexter.loadFromAssets(this, dex); } catch (Exception e) { throw new RuntimeException("Unable to load DEX files", e); } try { startActivity(new Intent(MainActivity.this, getClassLoader().loadClass("the real activity"))); } catch (ClassNotFoundException e) { throw new RuntimeException("Unable to start application", e); } } }