We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Creat list on Exchang

Hi,

Can we use this API to create list on Exchange List? We want to create list of our choice with contacts.

Hi Acton,


Thank you for posting your inquiry.

You can create Distribution list on Exchange Server using the EWSClient of Aspose.Email API. Please have a look at the following code sample for your reference and share your feedback with us.

Code:

IEWSClient client = EWSClient.GetClient(“Exchange Server URL”, “Username”, “Password”);
ExchangeDistributionList distributionList = new ExchangeDistributionList();
distributionList.DisplayName = “test private list”;
members = new MailAddressCollection();
members.Add("address1@host.com");
members.Add("address2@host.com");
members.Add("address3@host.com");
client.CreateDistributionList(distributionList, members);