Skip to content Skip to sidebar Skip to footer

How To Open Installed Applications Drawer Android By Button Click

how can I navigate to the applications page on my phone by a button click from my app? is it possible? UPDATE

Solution 1:

The question was not not ver clear earlier. I don't think it's possible. I have worked extensively on Android Launcher code and there's no standard or undocumented Intent to open that page directly.

Solution 2:

Nova Launcher has a shortcut provider which lets you choose any activity. Simply call this shortcut provider from you code and select the activity you want, and then simple record the returned Intent.

Though this intent not be universal for all android versions. It will have package name and component name (and not an action string).

Use this code in an Activity in a test project. Make sure you have Nova launcher installed (you can uninstall it later on)

publicvoidonTestButtonClicked(View v) {
  startActivityForResult(Intent.createChooser(newIntent(Intent.ACTION_CREATE_SHORTCUT), "Select Activities"), 10);
}

@OverrideprotectedvoidonActivityResult(int requestCode, int resultCode, Intent data) {
  if (requestCode == 10 && resultCode == RESULT_OK) {
    Intentintent= data.getParcelableExtra(Intent.EXTRA_SHORTCUT_INTENT);
    Log.e("Intent", intent.toUri(Intent.URI_INTENT_SCHEME));
  }
}

Post a Comment for "How To Open Installed Applications Drawer Android By Button Click"