我有一个添加联系人按钮,我希望它打开添加Windows手机的新联系人任务并返回添加的联系人
就像android我已经知道我可以添加联系人从问题Adding contacts to People on Windows Phone 8.1 in C#
中抛出以下代码using Windows.Phone.PersonalInformation;
public async void addPerson() {
var store = await ContactStore.CreateOrOpenAsync();
var contact = new StoredContact(store) {
DisplayName = "Mike Peterson"
};
var props = await contact.GetPropertiesAsync();
props.add(KnownContactProperties.Email, "mike@peterson.com");
props.add(KnownContactProperties.MobileTelephone, "+1 212 555 1234");
await contact.SaveAsync();
}