Address Book

  1. 4 months ago

    Is the example: AddressBook suposed to work, or has been deprecated?
    On my Mac the Address Book is called Contacts.

    On latest MacOS 10.14.6 and latest Xojo 19, 1.1.don't seem to work.

  2. Dave S

    Aug 10 San Diego, California USA

    yes.. it does not return any contacts....

  3. Jean-Yves P

    Aug 10 Pre-Release Testers, Xojo Pro Europe (France, Besançon)

    it works for me on 10.11.6 and latest Xojo.

  4. Dave S

    Aug 10 San Diego, California USA

    just found this

    3

    I heard back from a Developer Technical Support Engineer at Apple and he said:

    "I’ve asked the engineering team about this and indeed, we have removed support for both compiled and AppleScript-based AddressBook plugins in Mojave 10.14."

  5. Beatrix W

    Aug 10 Pre-Release Testers, Third Party Store Europe (Germany)

    You need to use CNContactStoreMBS from the MBS plugin. Even if I'm trying to be nice I can only call this monster insane.

  6. Sam R

    Aug 10 Pre-Release Testers, Xojo Pro, Third Party Store Hengchun, Pingtung, Taiwan

    @Enric H On latest MacOS 10.14.6 and latest Xojo 19, 1.1.don't seem to work.

    @Jean-YvesPochez it works for me on 10.11.6 and latest Xojo.

    In macOS 10.11, Apple introduced a new mechanism for accessing the "Address Book" / "Contacts". I am not at my work 'puter, but I suspect that if you look through Feedback you'll find requests to update to the newer API.

  7. MacOS 10.14.6 and Xojo 2019r1.1

    In my apps I succesfully retrieve data with this snippet:

    Dim book as AddressBook = System.AddressBook
    Dim Contacts() as AddressBookContact = book.Contacts
    Dim groups() as AddressBookGroup
    dim theData as addressBookData
    
    if UBound(Contacts) >= 0 then
      dim a, aa, z, mSplit(), temp as string
      For i as integer = 0 to Ubound(Contacts)
        a = ""
        a = contacts(i).firstname
        aa = contacts(i).lastName
        if a = "" and aa = "" then//avoid groups
        else
          if a <> "" then a = a + " "
          if aa <> "" then a = a + aa
          if a <> "" then a = trim(a) + " <"
          z = ">"
        end if
        thedata = contacts(i).emailaddresses
    //etcetera

    I used to use an applescript to let users import only contacts they wished. It was very handy, but a couple of years ago I disposed of it because I foresaw that sooner or later MAS might force me to remove it. Thanks, Apple, for helping us cripple our apps.

or Sign Up to reply!