Reputation: 845
I am building an application using ionic and cordova. I am trying to open an external application to which source code I dont have any access. I only know the package name. Is what I am trying to do actually possible?
CDV.WEBINTENT.startActivity({
action: CDV.WEBINTENT.ACTION_VIEW,
url: "content://com.test.123.GameActivity"
},
function() {},
function() {
alert('Failed to open URL via Android Intent')
});
Upvotes: 0
Views: 1407
Reputation: 11
Have you looked at this tutorial?
how-to-launch-external-application-with-ionic-framework
And if that helps, this is how you would do it in Java:
Intent launchIntent = getPackageManager().getLaunchIntentForPackage("package name here");
startActivity(launchIntent);
Upvotes: 1