Work with Conversations in MS Exchange Server in C#

The conversations on Microsoft Exchange Server are referred to as the group of email messages in a thread. In simple words, an email and all its replies are known to be a conversation. In this article, we will show you how to work with conversations in MS Exchange Server programmatically. Particularly, you will learn how to find, copy, move and delete conversations on MS Exchange Server in C# .NET.

C# .NET API to Work with Conversations on MS Exchange Server

To manage the conversations on Microsoft Exchange Server, we will use Aspose.Email for .NET. It is a powerful API that provides a range of features to implement email client applications. Also, it allows you to access various services of MS Exchange Server seamlessly. You can either download the API’s DLL or install it from NuGet using the following command.

PM> Install-Package Aspose.Email

Find Conversations on MS Exchange Server in C#

The following are the steps to find conversations from a folder in MS Exchange Server in C#.

The following code sample shows how to find conversations from a folder in MS Exchange Server in C#.

Copy a Conversation on MS Exchange Server in C#

You can also copy the conversations from one folder to another without writing a complex code. For demonstration, let’s have a look at how to copy conversations from the inbox to deleted items folder of Exchange Server in C# .NET.

The following code sample shows how to copy a conversation in MS Exchange Server using C# .NET.

Move a Conversation on MS Exchange Server in C#

In the previous section, we just copied conversations from one folder to another. However, in certain cases, you may need to move a conversation to a particular folder. The following are the steps to move conversations in MS Exchange Server in C# .NET.

The following code sample shows how to move a conversation in MS Exchange Server using C# .NET.

Delete a Conversation on MS Exchange Server in C#

Last but not the least, let’s have a look at how to delete a conversation from MS Exchange Server in C#.

The following code sample shows how to delete a conversation from MS Exchange Server in C# .NET.

Get a Free API License

You can get a free temporary license to use Aspose.Email for .NET without evaluation limitations.

Conclusion

In this article, you have learned how to manage conversations in Microsoft Exchange Server using C#. You have seen how to find, copy, move, and delete conversations on MS Exchange Server programmatically in C#. In addition, you can explore the documentation to read more about Aspose.Email for .NET. Also, you can ask your questions via our forum.

See Also