Click or drag to resize

ImapClientSearchMessageNumbers Method

Searches for messages on the server that match the specified criteria.

Namespace:  GemBox.Email.Imap
Assembly:  GemBox.Email (in GemBox.Email.dll) Version: 11.3.30.1034
Syntax
public ReadOnlyCollection<int> SearchMessageNumbers(
	string query
)

Parameters

query
Type: SystemString
A search criteria string.

Return Value

Type: ReadOnlyCollectionInt32
Read-only collection of message numbers that match specified criteria.
Exceptions
ExceptionCondition
InvalidOperationException No folder is selected or Client is not connected or Server error.
ArgumentException Query is null or empty.
Remarks
Method executes SEARCH command against the server and returns a list of message numbers that match specified criteria. Query is constructed of one or more search keys as defined in RFC 3501 - section 6.4.4.
See Also