简体   繁体   English

如何打开com.android.contacts / .CallDetalActivity

[英]how to open com.android.contacts/.CallDetalActivity

i want to open calldetail activity to see a contact call log info. 我想打开calldetail活动以查看联系人通话记录信息。

i take uri with this code 我用这个代码uri

Uri lookupUri = Uri.withAppendedPath(CallLog.Calls.CONTENT_FILTER_URI, Uri.encode(c1.getString(c1.getColumnIndex(CallLog.Calls.NUMBER))));

now if i use 现在,如果我使用

    Intent intent = new Intent(Intent.ACTION_VIEW,lookupUri);
    startActivity(intent);

it opens the calls tab on my phone but not the calldetail activity. 它会打开我手机上的“通话”标签,但不会打开calldetail活动。 how can i display calldetail activity with lookupUri? 如何使用lookupUri显示calldetail活动?

EDIT: thanks to commonsware i've did it modyfing 编辑:感谢commonsware我做了modyfing

Uri lookupUri = Uri.withAppendedPath(CallLog.Calls.CONTENT_URI, Uri.encode(c1.getString(c1.getColumnIndex(CallLog.Calls._ID))));

尝试将CallLog.Calls.CONTENT_TYPE添加为Intent的MIME类型。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何保存从com.android.contacts,Android中提取的图像? - How to save image extracted from com.android.contacts, Android? android 中 content://com.android.contacts 的用途是什么 - What is use of content://com.android.contacts in android android联系人源代码com.android.contacts - android contact source code com.android.contacts 执行applyBatch时未找到权限com.android.contacts异常 - Authority com.android.contacts not found exception when doing applyBatch ShowCallLog Intent 在由“com.android.contacts”处理时不起作用 - ShowCallLog Intent not working when handled by "com.android.contacts" java.io.FileNotFoundException:content://com.android.contacts/contacts/24093/photo仅适用于旧照片 - java.io.FileNotFoundException: content://com.android.contacts/contacts/24093/photo for old photos only 使用什么代替Contacts.Intents.UI.LIST_STARRED_ACTION在com.android.contacts中显示已加星标的联系人? - What to use instead of Contacts.Intents.UI.LIST_STARRED_ACTION to display starred contacts in com.android.contacts? Adobe air内容:\\\\ com.android.contacts \\ display_photo \\加载照片 - Adobe air content:\\com.android.contacts\display_photo\ load a photo 未能为用户 0 找到提供者 com.android.contacts,预计会为此权限找到有效的内容提供者 - failed to find provider com.android.contacts for user 0, expected to find a valid contentprovider for this authority 无法传递结果ResultInfo {who = null,request = 1,result = -1,data = Intent {dat = content://com.android.contacts/contacts/lookup…}} - Failure delivering result ResultInfo{who=null, request=1, result=-1, data=Intent { dat=content://com.android.contacts/contacts/lookup…}}
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM