×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Regular Contributor
    Join Date
    Mar 2006
    Location
    India
    Posts
    138

    Question How to use a new contact template to create a new contact in the Contact appliaction

    Hi,

    I want to create a new contact template and want to use it in contact application to creat a new contact.
    I tried with following code but I m not able to find any contact tempalate through contact application.

    CContactDatabase* cdb = CContactDatabase::OpenL();
    CleanupStack::PushL(cdb);


    _LIT(KWorkLocation,"KWorkLocation");
    _LIT(KMyName,"MyName");
    _LIT(KTitle,"LMTitle");

    TBuf<20> landmark;
    landmark.Copy(KWorkLocation);


    CContactItemField* field1 = CContactItemField::NewL(KStorageTypeText,KUidContactOwnCard );

    landmark.Copy(KMyName);
    field1->SetLabelL(landmark.Right(landmark.Length()));
    field1->TextStorage()->SetTextL(KTitle);
    itemTemp->AddFieldL(*field1);

    CContactItem* itemTemp = cdb->CreateContactCardTemplateL(landmark.Right(landmark.Length()));

    cdb->CloseContactL(itemTemp->Id());

    So I have the following two issue:
    1. How to use an existing template to create a new contact as a user of the contact application
    2. How to make able a contact template created programatically to be used by user.

    Thanks
    Anand Jain
    Thanks
    -Anand

  2. #2
    Regular Contributor
    Join Date
    Apr 2006
    Location
    India
    Posts
    383

    Re: How to use a new contact template to create a new contact in the Contact appliaction

    Hi!

    See the class CPbkContactEditorDlg.
    Check the phonebook example.
    This may help u.
    Regards,
    Shilpa Kulkarni

  3. #3
    Regular Contributor
    Join Date
    Mar 2006
    Location
    India
    Posts
    138

    Question Re: How to use a new contact template to create a new contact in the Contact appliaction

    Hi
    While calling Panic CContactDatabase::PhonebookGroupIdL() for the default contact database, it gives "Panic Etel Fault 20"

    PLease help me thanks! it is urgent!!

    Actually I want to add some more field to the contact template of the phonebook application.

    Thanks
    -Anand

  4. #4
    Regular Contributor
    Join Date
    Mar 2006
    Location
    India
    Posts
    138

    Question Re: How to use a new contact template to create a new contact in the Contact appliaction

    Quote Originally Posted by Shilpa13
    Hi!

    See the class CPbkContactEditorDlg.
    Check the phonebook example.
    This may help u.
    Hi I m not able to find PhoneBookex .. is it the same as AddressBook..

    Can u send me the link..
    Thanks
    _anand

Similar Threads

  1. How to create a contact item in 7650 SDK?
    By mparkkon in forum Symbian C++
    Replies: 15
    Last Post: 2008-09-02, 07:39
  2. Python build problem
    By Santehnik.UA in forum Python
    Replies: 7
    Last Post: 2008-07-21, 07:34
  3. Replies: 4
    Last Post: 2006-10-12, 09:56
  4. Unwanted contact template fields...
    By ashbhatia in forum Symbian C++
    Replies: 1
    Last Post: 2006-10-07, 10:55
  5. ARMI Template error
    By moldovan_catalin in forum Symbian C++
    Replies: 2
    Last Post: 2005-09-20, 07:39

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •