How to get the user selection from startActivityFo

2019-01-19 04:21发布

Is there any way to get programmatically the user selection after

startActivityForResult(Intent.createChooser(fileIntent, "Open file using..."), APP_PICKED);

or

startActivity(Intent.createChooser(fileIntent, "Open file using..."));

I do not want to start the selected application - I only want to know which one is it?

Thanks!

1条回答
够拽才男人
2楼-- · 2019-01-19 04:33

No, you cannot find out what the user chose.

You can, however, use PackageManager and queryIntentActivities() to make your own chooser.

查看更多
登录 后发表回答