按下指定的输入字段时打开联系人活动
我想在按下 webview 中的输入字段(文本)时启动联系活动。不知道我该怎么做。尝试在网络上搜索,但我得到的唯一结果是如何在按下“输入文件字段”时启动文件浏览器。 Android 似乎有一个专门用于此目的的选项,但当另一个选项时则不然输入类型被按下?
我真正想做的是;
当按下输入字段时,我想为用户提供一个选项来启动联系人管理器(或类似的东西)以从其联系人列表中选择一个或多个联系人。
然后在输入字段中填写联系人电子邮件地址,并用逗号分隔。
可以这样做吗?知道我应该在网上搜索什么吗?
I want to launch an contact-activity when a input-field (text) in a webview is pressed. Not sure how I can do this. Have tried to search the web but the only results I get is how to launch a filebrowser when a "input-file-field" is pressed.. And it seems like Android have an option that is exactly for that purpose, but not when another input-type is pressed?
What I actually want to do is;
when the input field is pressed, I want to give the user an option to launch the contact manager (or something similar) to choose one or more contacts from its contactlist.
Then fill the input-field with the contacts emails, separated with commas.
Is it possible to do this? Any idea what I should search the web for?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
解决了!添加了一个新类:
并使用这是我的 WebView 类:
这是我在输入上的 html:
然后我使用新活动创建了类“ListContacts.class”。
Solved! Added a new class:
And uses this is my WebView class:
And this is my html on the input:
Then i created the class "ListContacts.class" with a new activity.