Connecting to Exchange Server using WebDav

Connect to Exchange using ExchangeClient

The following code samples depict writing a custom function that can be called in code segments for instantiating ExchangeClient, which can then be used to carry out various Exchange operations.

// For complete examples and data files, please go to https://github.com/aspose-email/Aspose.Email-for-Java
public static ExchangeClient getExchangeClient() {
// Create instance of ExchangeClient class by giving credentials
ExchangeClient client = new ExchangeClient("http://MachineName/exchange/Username", "Username", "password", "domain");
return client;
}