Android: How to save contacts to sdcard as vCard. Without duplicates?
问题 I am trying to save all of the contacts on a phone to the sdcard as a .vcf file (vCard). It works, but I have a problem. Every contact that has more than one phone number (a mobile and work number) are saved twice. And both of the numbers are in each duplicate contact, so they are correct, just duplicated. Can someone please tell me how to fix this problem? My code is: File delete=new File(Environment.getExternalStorageDirectory()+"/Contacts.vcf"); if (delete.exists()) { delete.delete(); }