ALL OF THE ABOVE ANSWERS OPEN GOOGLE PLAY IN A NEW VIEW OF THE SAME APPAll of the above answers open Google Play in a new view of the same app, IF YOU ACTUALLY WANT TO OPEN GOOGLE PLAYif you actually want to open Google Play (or any other app)INDEPENDENTLY independently:
Intent launchIntent = getPackageManager().getLaunchIntentForPackage("com.android.vending");
// package name and activity
ComponentName comp = new ComponentName("com.android.vending",
"com.google.android.finsky.activities.LaunchUrlHandlerActivity"); // package name and activity
launchIntent.setComponent(comp);
// sample to open facebook app
launchIntent.setData(Uri.parse("market://details?id=com.facebook.katana"));
startActivity(launchIntent);
The important part is that actually opens google play or any other app independently.
(Most of what I have seen uses the approach of the other answers and it was not what i needed hopefully this helps somebody) Most of what I have seen uses the approach of the other answers and it was not what I needed hopefully this helps somebody.
Regards.