qt - What's wrong with this piece of code for saving contacts? -


I am using the latest Nokia QT SDK. I have tried to add contacts, it is not being added .. What is missing in it?

  // Create a Contact Manager for the default contact backend; QCactact Manager * cm = new cachetector manager ("simulator"); // QContactManager * cm = new QContactManager ("memory"); // I tried it, it does not work too // Create an example example contact QContact; // Add contact name; QContactName name; Name.setFirstName ("John"); Name.setLastName ("do"); Example.saveDetail (& amp; Name); // Add Contact Email Address // QContactEmailAddress Email; // email.setContexts (QContactDetail :: ContextHome); //email.setEmailAddress("john.doe@example.com "); // example.saveDetail (& amp; email); // Finally, save contact details- cm- & amp; SaveNews (& amp; Examples); Deleting cm;  

thanks

http: // doc Qt .nokia.com / qtmobility-1.0-tp / qcontactmanager.html # availableManagers Check the list of available managers, and use one of them may be that it will work


Comments

Popular posts from this blog

windows - Heroku throws SQLITE3 Read only exception -

lex - Building a lexical Analyzer in Java -

python - rename keys in a dictionary -