Internet Direct (Indy) Version 9.0.1 Beta
TIdIMAP4.DeleteMsgs
Marks the specified messages for subsequent deletion when a mailbox is purged.

function DeleteMsgs(const AMsgNumList: array of Integer): Boolean; overload;
Parameters
const AMsgNumList: array of Integer
Array of messge numbers to mark for deletion.

Returns
Boolean - True on success.

Description
DeleteMsgs is a Boolean function that marks the specified messages in AMsgNumList for subsequent deletion when the mailbox is purged. DeleteMsgs calls StoreFlags to add the TIdMessageFlag value mfDeleted to the flags stored in the message on the IMAP4 server.