0

I've been searching and I couldn't find a topic that could clarify me 100%.

My question is: How can I launch an android's app preferences activity (from Contacts, Messages, ...) on my own app?

I give an example: Imagine I'm developing an app which allows the user to quickly access to Message's Settings. I don't need to send or receive any information, I only need to open the activity, create a shortcut for it.

4

3 回答 3

1

在代码中编写 Explicit Intent 将转到您的应用程序的特定活动并使用相同的格式转到其他应用程序的特定活动没有区别。需要注意的几件事: (1) 接收活动可能期待特定数据,否则会失败。(2) 您正在考虑的标准应用程序,例如联系人、消息,而您可以在 Android 开源项目 (AOSP) 中找到它们的来源,制造商可能会更改它们,因此活动名称和必要的额外数据可能会有所不同。

为了在所有不同的 Android 制造商之间保持尽可能多的兼容性,您应该坚持使用适当的操作/数据的标准隐式意图。

于 2012-07-31T05:04:01.603 回答
1

The best answer in this thread has the solution: android: how do i open another app from my app?

Also check: http://android-developers.blogspot.com/2009/01/can-i-use-this-intent.html

To open settings, you can try: startActivityForResult(new Intent(android.provider.Settings.ACTION_SETTINGS, 0));

于 2012-07-30T23:40:27.300 回答
1

Someone knows if this can be done and even opening specific locations of the apps?

You don't need to know any specific locations or specific apps for these actions, simply look into Intent.ACTION_PICK.

于 2012-07-30T23:42:50.567 回答