ImapClientUnselectFolderAsync Method (IConnection, Boolean, CancellationToken)

Unselects folder which are currently selected. if doNotExpunge property is true, all messages are marked as deleted are removed, otherwise deletion canceled. Please note, this operation works only in case if server supports RFC3691 See more https://tools.ietf.org/html/rfc3691

Namespace:  Aspose.Email.Clients.Imap
Assembly:  Aspose.Email (in Aspose.Email.dll) Version: 22.4
Syntax
public Task UnselectFolderAsync(
	IConnection connection,
	bool doNotExpunge,
	CancellationToken token
)

Parameters

connection
Type: Aspose.Email.ClientsIConnection
Connection to a server
doNotExpunge
Type: SystemBoolean
Specifies whether messages marked as deleted should be removed.
token
Type: System.ThreadingCancellationToken
Propagates notification that operations should be canceled.

Return Value

Type: Task
Task object, with delegate for this operation
See Also