Sunday, July 12, 2020

How to open an APP in Google Play Store

How the open an APP in Google Play Store Programatically

In Android Programming we can open Play Store with a Given App Package Name.
The following method opens Apps' playstore page

void openAppInPlaystore(String appPackageName )
        try {
            startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + appPackageName)));
        } catch (android.content.ActivityNotFoundException anfe) {
            startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("" + appPackageName)));

1 comment:

  1. This is really a good source of information, I will often follow it to know more information and expand my knowledge, I think everyone should know it, thanks. Get more info about What is Toast and How to use it with Examples at