iOS Code Snippet Add Contact to Address Book(Iphone Contacts)

Discussion in 'iOS Code Snippets' started by narek adonts, Mar 22, 2015.

  1. narek adonts

    narek adonts Well-Known Member Licensed User

    Hi

    A code to add contact to Iphone Contacts with First Name, Last Name, Phone Number and Image

    I almost dont understand anything about Objective C
    If there is someone more experienced then me, this module can me extended to have a full Contacts Class.

    You Should Initialize the module first.

    Please see attached the module

    Narek
     

    Attached Files:

  2. Brian Robinson

    Brian Robinson Active Member Licensed User

    Hi,

    Does this code snippet actually work. Do you have any examples of it working?

    I had a quick look at the Obj-C and there is a lot in there that is not needed. It was in the original code that was adding Pets to their contacts list (that's why the name AddPetToContacts). But the first part of it is setting up a record to insert. we don't need that because we are passing in the parameters.

    I can clean it up and try and get it to bring back the list as well

    Cheers
    Brian
     
    Last edited: Mar 26, 2015
  3. narek adonts

    narek adonts Well-Known Member Licensed User

    This code works. I didnt managed to clean the code.

    Narek
     
  4. Brian Robinson

    Brian Robinson Active Member Licensed User

    I have cleaned this a little to make it a bit more usable. Will be adding phone numbers etc to it, once I think I am on the right track.

    Oh yes, I have my provision and .cer files in the code. The reference to those will need to be removed.

    Cheers
    Brian
     

    Attached Files:

  5. kemanlam

    kemanlam Member Licensed User

Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice