How to access and change contacts in Windows 8?

I found a new contacts API in Windows 8: http://msdn.microsoft.com/en-us/library/windows/apps/windows.applicationmodel.contacts%28v=VS.85%29.aspx

However, I can’t find out how to list all contacts and add or remove a contact.

Any clues?

+6
source share
2 answers

Check out the Contact Picker sample. You cannot just change contacts, you must first select them for you. This is done using the pickSingleContactAsync () method. This gives you a ContactInformation object that you can request or modify.

+3
source

Contacts Allows your application to create a new contact. Available only if your application uses the Contact contract.

PickMultipleContactsOperation Launches the Contact Picker user interface to select multiple contacts.

PickSingleContactOperation Launches the Contact Picker user interface to select a single contact.

These three classes and / or methods will do everything you need, except to delete the contract, which, I hope, will not be open to the application.

Remember that documentation and APIs are not complete.

+2
source

Source: https://habr.com/ru/post/899468/


All Articles