I just wanted to "help" my users to give feedback to my app by providing a button to launch Market. Found a working solution here, of course, which does:
Uri uri = Uri.parse("market://details?id=<mypackagename>");
Intent intent = new Intent (Intent.ACTION_VIEW, uri);
startActivity(intent);
Simple as that, thanks!
But: on my first run, I had that on my emulator. Gives an ActivityNotFoundException
immediately.
Now, my question: is there a way to find out whether a call to this intent will succeed BEFORE I try it? That way I could hide the button completely to not even give the option.
Thanks for your much appreciated help!