dimanche 24 mai 2015

How to Launch an android app from other app and give it a file name, so launched app open this file and do its default view operation?

I have an android app and I want to launch another app within my app. I know that I can get intent and run the desired app by following procedure:

Intent intent = getPackageManager().getLaunchIntentForPackage("pacage_name");
startActivity(intent);

But how we can include a parameter, for example a file name, which app can open and operate on it.

Suppose we don’t know the structure of app’s activities. It can be any standard android app (such as gallery). We know that it can get a parameter and operate on it.

In general, how android system launch an app and pass it a file name to operate on it?

Aucun commentaire:

Enregistrer un commentaire