views:

53

answers:

2

I am maintaining an in-house ASP.NET web app, part of which includes a Customer Relationship Management module for our sales team. One of the things they want is to be able to export all their contacts out of our database into their wide variety of email clients (Outlook on Windows, allsorts on Mac) and phones (IPhones, Blackberries - probably Androids). vCard seems to be the standard way to transfer contact information, but...

  1. Is it possible to specify multiple contacts in a single vCard by concatenating the vCard BEGIN/END blocks?
  2. Is vCard import support uniform, or are there quirks between clients?
  3. Any other tips/tricks/gotchas?
+1  A: 

Hi,

I can help you with the first question, in that outlook does not like multipule vCards in one file, you would have to do one file one contact.

Marcus

76mel
+1  A: 
  1. You can concatenate vCards, just put an empty line between each vCard (the standard actually requires an empty line after the END line).
  2. Import support is sketchy. Outlook will import pretty much anything, but often loses data in the process (at least when I tried it a few years ago). Thunderbird supports vCards in emails, but doesn't import vCards from file without a plugin. Gmail actually has the best vCard support I've ever seen, importing many fields successfully, including even base64 JPEG images. Many people I've communicated with complain about my attached vCard, because their client / webmail site doesn't know what to do with it. Shame really; it's the only alternative we've got for easy contact info exchange.
  3. Don't expect any tool to generate valid vCard. Also, most vCards out there are not valid according to the standard (even those embedded in the standard itself!). I developed a vCard validator (first result on Google, surprisingly) because of this - It's not complete, but it invalidates almost every vCard I've found online, generated or not. It became clear during development that the standard is quite spotty - Some places it's specified that things are case insensitive, some places it seems like it should be but it's not mentioned, some things are really hard to parse (such as ISO dates), there's no namespace support (X-properties can be used), the recommended line break system is a pain, and so on.
l0b0