Author Topic: Can't import contacts into Address Book  (Read 4260 times)

Offline heinelg

  • Newbie
  • *
  • Posts: 2
Can't import contacts into Address Book
« on: July 03, 2013, 02:28:24 PM »
When I try to import a list of contacts in a .csv file into either the Address Book or the Global Address Book I only get the First Name and Last Name but not the e-mail address or phone number.

I shortened the file to four fields (First Name, Last Name, Name, E-mail Address) and the same thing happens.

What is the proper organization of the .csv file for import or does this feature not work?

Thanks!

Larry

Offline alec

  • Hero Member
  • *****
  • Posts: 1,152
Re: Can't import contacts into Address Book
« Reply #1 on: July 04, 2013, 02:10:20 AM »
In csv file you need to have a header line with field names. List of supported labels you can find in lib/Roundcube/rcube_csv2vcard.php file, it's $label_map array. Finally, because of a bug I found now, all values need to be inside quotes.

Offline heinelg

  • Newbie
  • *
  • Posts: 2
Re: Can't import contacts into Address Book
« Reply #2 on: July 07, 2013, 08:31:10 AM »
Thanks, Alec,

My CSV file has a header row.

I created a short file (Header Row and 6 names with e-mail addresses) for test purposes. My header row is: First Name,Last Name,E-mail Address

This is what I found:

1. First Name and Last Name were imported correctly with or without quotes (" ") around values
2. If I put " " around e-mail address values, first name and last name were still imported correctly but e-mail address was not imported
3. If I put ' ' around e-mail address values, nothing was imported

Is the order of the values in the CSV file important? Do you have any other suggestions?

Thanks!