ImapSubscribeFolder Method
Subscribes to the specified folder (mailbox in IMAP4 terms) of the IMAP4 account.

Namespace: MailBee.ImapMail
Assembly: MailBee.NET (in MailBee.NET.dll) Version: 11.2.0 build 590 for .NET 4.5
Syntax
public bool SubscribeFolder(
	string folderName
)

Parameters

folderName
Type: SystemString
The full name of the folder to be subscribed.

Return Value

Type: Boolean
true if the folder was subscribed successfully; otherwise, false.
Exceptions
ExceptionCondition
MailBeeExceptionAn error occurred and ThrowExceptions is true.
Remarks

This method adds the specified folder to the server's set of "active" or "subscribed" folders as returned by DownloadFolders(Boolean) method when subscribedOnly is set to true.

The developer should specify the full name of the folder (including all parent folders' names if the folder is subfolder of another existing folder). See CreateFolder(String) topic for details regarding folder names.

To subscribe to a folder asynchronously, see the sample code in BeginExecuteCustomCommand(String, String, AsyncCallback, Object) topic.

See Also