Search code examples
androidsmscontactsmmsvcf-vcard

Android - How to send/read vCard via SMS/MMS?


I'm looking for any way to send/read a vCard via SMS in my app. I've read a lot of articles, web-pages, forums etc. There is still not even a clue how to do that.

Here is transaction.

  1. User selects some specific contact
  2. App generates a vCard for it
  3. User types a number to send vCard to
  4. App sends SMS with that vCard(?)
  5. Addressee recievs SMS with vCard and asked to browse contact/add to contacts(?)

Here is some posts in stackoverflow with the same issue: this and this. Still nothing helpful...

I've found this nice library to work .vcf files(both write and read). But is there any way to send it to another phone (and read properly of course)? Just send this as a string maybe?

HERE is a nice stack post about handling data from recieved SMS sent by SMSManager.sendDataMessage() method

Please help! I'll be happy to get any clue, useful library or a proof that it's impossible on Android. If there is no way via SMS can you give me advice how to do that via MMS?

What's interesting, that there is a lot of apps with that functionality, so I guess this is possible.

Thanks anyone who responds. Have a good day.


Solution

  • You don't have to read MMS from code, when you have system for that.

    To send MMS with vCard, you need to attach .vcf file to it.

    Here is an answer how to do that.