contacts

Read all contacts' phone numbers in android

与世无争的帅哥 提交于 2019-12-16 22:40:08
问题 I'm using this code to retrieve all contact names and phone numbers: String[] projection = new String[] { People.NAME, People.NUMBER }; Cursor c = ctx.getContentResolver().query(People.CONTENT_URI, projection, null, null, People.NAME + " ASC"); c.moveToFirst(); int nameCol = c.getColumnIndex(People.NAME); int numCol = c.getColumnIndex(People.NUMBER); int nContacts = c.getCount(); do { // Do something } while(c.moveToNext()); However, this will only return the primary number for each contact,

friend finder api, to retrieve contacts from gmail,yahoo and hotmail using java [closed]

时光毁灭记忆、已成空白 提交于 2019-12-16 18:03:15
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed last year . Hi I am developing an web app a java/j2ee based web app, where I have provide an feature to all the users of my web portal, to access there gmail hotmail or yahoo account and should be able to send the the content in HTML format via e-mail to his contacts or friends. I am aware there are lot of PHP api's available

Android开发指南-框架主题-内容提供器

蓝咒 提交于 2019-12-15 16:29:58
【推荐】2019 Java 开发者跳槽指南.pdf(吐血整理) >>> 内容提供器Content Providers 内容提供器用来存放和获取数据并使这些数据可以被所有的应用程序访问。它们是应用程序之间共享数据的唯一方法;不存在所有Android软件包都能访问的公共储存区域。 Android为常见数据类型(音频,视频,图像,个人联系人信息,等等)装载了很多内容提供器。你可以看到在android.provider包里列举了一些。你还能查询这些提供器包含了什么数据(尽管,对某些提供器,你必须获取合适的权限来读取数据)。 如果你想公开你自己的数据,你有两个选择:你可以创建你自己的内容提供器(一个ContentProvider子类)或者你可以给已有的提供器添加数据-如果存在一个控制同样类型数据的内容提供器且你拥有写的权限。 这篇文档是一篇关于如何使用内容提供器的简介。先是一个简短的基础知识讨论,然后探究如何查询一个内容提供器,如何修改内容提供器控制的数据,以及如何创建你自己的内容提供器。 内容提供器的基础知识Content Provider Basics 内容提供器究竟如何在表层下保存它的数据依赖于它的设计者。但是所有的内容提供器实现了一个公共的接口来查询这个提供器和返回结果-增加,替换,和删除数据也是一样。 这是一个客户端直接使用的接口,一般是通过ContentResolver对象

Whats the fastest way to create large numbers of contacts?

大憨熊 提交于 2019-12-14 03:19:42
问题 In my application i need to create a great amount of contacts. The code I currenly use: ArrayList<ContentProviderOperation> ops = new ArrayList<ContentProviderOperation>(); ops.add(ContentProviderOperation.newInsert(ContactsContract.RawContacts.CONTENT_URI) .withValue(ContactsContract.RawContacts.ACCOUNT_TYPE, accounts[0].type) .withValue(ContactsContract.RawContacts.ACCOUNT_NAME, accounts[0].name) .build()); ops.add(ContentProviderOperation.newInsert(ContactsContract.Data.CONTENT_URI)

Intent Filter for handling address press in Contact?

风流意气都作罢 提交于 2019-12-14 02:22:14
问题 Folks, when viewing a contact, you can press on the address to view that address in a map application (such as Google Maps or VZW Navigator). I would like define an intent-filter such that my app will show up in the list of apps that can handle said intent. Any ideas? Thanks in advance. From logcat, I see the following from ActivityManager: Starting activity: Intent { act=android.intent.action.VIEW dat=content://com.android.contacts/data/6792 cmp=android/com.android.internal.app

SpriteKit / Swift - How to check contact of two nodes when they are already in contact

泪湿孤枕 提交于 2019-12-14 00:27:52
问题 In my game, when the game begins, some nodes are already in contact but I don't find how to detect these contacts. I only succeed to detect contacts that happen when nodes are moving and getting in contact during the game using the function didBeginContact. Anyone has an idea please how to detect these contacts? Here is my didBeginContact if needed: func didBeginContact(contact: SKPhysicsContact) { var firstBody: SKPhysicsBody var secondBody: SKPhysicsBody if contact.bodyA.categoryBitMask ==

Android: set contact photo with ContactsContract insert intent

瘦欲@ 提交于 2019-12-13 12:40:23
问题 I am using ContactsContract to insert a new contact by sending the user to a "New contact" intent. The code I am using is: Intent i = new Intent(Intent.ACTION_INSERT); i.setType(Contacts.CONTENT_TYPE); i.putExtra(Insert.NAME, "Some Contact Name"); i.putExtra(Insert.EMAIL, "address@email.com"); i.putExtra(Insert.PHONE, "123-456-7890"); startActivity(i); However, I need to also somehow pass in a locally stored photo (in res/drawable) to show up on this "New contact" intent. I was hoping that

How to fetch only WhatsApp Contacts from iPhone Contacts?

喜欢而已 提交于 2019-12-13 09:44:08
问题 How can I fetch only WhatsApp contacts from iPhone contact list using swift. I fetched contacts information from my phone got following response: whats app contact <CNContact: 0x13bd92310: identifier=04B80557-011F-4437-B132-43E2B0D70CD9, givenName=Tech, familyName=.vijaykart, organizationName=, phoneNumbers=("<CNLabeledValue: 0x170661e80: identifier=579A8A18-F113-4C6E-878A-68D18BFE4A8B, label=_$!<Mobile>!$_, value=<CNPhoneNumber: 0x17023f420: countryCode=in, digits=+919791291980>>"),

How to fetch contacts NOT named “John” with Swift 3 [closed]

徘徊边缘 提交于 2019-12-13 09:33:54
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed 2 years ago . Is there a way I can fetch contacts using the Contacts framework without an attribute? Example: myContactArray = unifiedContactsNotCalled("John") PS: I know that line is nothing like the real code, it's just a serving suggestion for illustrative purposes 😉 回答1: Before I outline

contacts interception

这一生的挚爱 提交于 2019-12-13 08:48:34
问题 is there any posibilty to intercept the contact. if user add,delete and update any contact system notify that changes occur in the contact. thanks 回答1: You can register a data observer on the relevant ContactsContract content provider. 来源: https://stackoverflow.com/questions/2672809/contacts-interception