Hi,
I have two problems the first one if I update a contact (for example a phone number) we lost the photos linked to him.
and
If I try to update a contact to add a photo, I get an exception.
IEWSClient client = EWSClient.GetEWSClient(“Url”, CredentialCache.DefaultNetworkCredentials);
MapiContact[] contacts = client .ListContacts(client.MailboxInfo.ContactsUri);
MapiContact c in contacts[0];
c.Telephones.MobileTelephoneNumber = “000000000000”;
client.UpdateContact©; // lost of images
/* Same beginning of code*/
c.Photo = new MapiContactPhoto(data, format); /* data is File.ReadAllBytes, format is the one corresponding to the selected photo generally MapiContactPhotoImageFormat.Jpeg/
client.UpdateContact©; // Exception
/
Object reference not set to an instance of an object.
at #=q0j6sve9S0kQRf$2i$i$OT3iYyGG8klnuRiMmnv0n5fn0kUyrUTbDDmd3Vurwhi$7GT0Qe5GbTNO3y6O8FIj61A==.#=qXQi2dTQyS09CE7ezpeMFzQ==()
at #=qfRXfyPuyzdEg71lIWeSugyuWFMRdWQnIEskGoKgkywRbBO7Pq1VUo9BtEJwcpk3o.#=qmIG70MlC_H5naJQ8frearw==()
at Aspose.Email.Mail.Contact.op_Implicit(MapiContact contact)
*/
Best regards