EwsDownloadItem Method (ItemId, EwsItemParts)
Downloads the specified portions of the specified item by its ID.

Namespace: MailBee.EwsMail
Assembly: MailBee.NET (in MailBee.NET.dll) Version: 12.3.0 build 647 for .NET 4.5
public EwsItem DownloadItem(
	ItemId id,
	EwsItemParts parts


Type: ItemId
The ID of the item. Null reference (Nothing in Visual Basic) not allowed.
Type: MailBee.EwsMailEwsItemParts
The settings which specify which portions of MS Exchange items to download (e.g. item ID, mail header, body, etc). You can combine multiple values.

Return Value

Type: EwsItem
The downloaded item, or a null reference (Nothing in Visual Basic) on error.
MailBeeExceptionAn error occurred and ThrowExceptions is true.
NotImplementedExceptionThe .NET runtime is .NET Core.

To get item IDs, you can use DownloadItemIds(FolderId, Boolean) or Search(FolderId, SearchFilter) methods and then pass Id of items of the returned list to the current method.

In advanced cases, you can store UniqueId string in database and later recreate ItemId object using #ctor(String) constructor. Then you can supply that object to this method. This is useful in case if you need to get IDs for items and items themselves at different times.

Note Note
This method is not implemented in .NET Core. Use DownloadItemAsync(ItemId, EwsItemParts) instead.
See Also