Click or drag to resize
MimeKit

ImapClientGetFolder Method (SpecialFolder)

Get the specified special folder.

Namespace:  MailKit.Net.Imap
Assembly:  MailKit (in MailKit.dll) Version: 2.14.0
Syntax
C#
public override IMailFolder GetFolder(
	SpecialFolder folder
)

Parameters

folder
Type: MailKitSpecialFolder
The type of special folder.

Return Value

Type: IMailFolder
The folder if available; otherwise null.

Implements

IMailStoreGetFolder(SpecialFolder)
IMailStoreGetFolder(SpecialFolder)
Exceptions
ExceptionCondition
ArgumentOutOfRangeExceptionfolder is out of range.
ObjectDisposedException The ImapClient has been disposed.
ServiceNotConnectedException The ImapClient is not connected.
ServiceNotAuthenticatedException The ImapClient is not authenticated.
NotSupportedException The IMAP server does not support the SPECIAL-USE nor XLIST extensions.
Remarks
Not all IMAP servers support special folders. Only IMAP servers supporting the SpecialUse or XList extensions may have special folders.
See Also