TransportDel

The TransportDel function deletes a specific message located on the mail server.

Syntax

BOOL TransportDelete(HANDLE hService, MailMsg *MsgPtr);

At a Glance

Header file: Smtp.h
Platforms: H/PC
Windows CE versions: 1.0 and later

Parameters

hService
Handle to a SERVICE structure.
MsgPtr
Pointer to the MailMsg structure. The message to be deleted is specified by the szSvcId member of the specified MailMsg structure. This member is compared with the message identifiers stored in the Uids member of the specified SERVICE structure. The information maintained in hService is then used in support of deleting the message.

Return Values

Returns TRUE if successful or FALSE otherwise. To get extended error information, call TransportError or TransportErrorMsg. For example, if the message identifier cannot be found, the iErr member of the specified MailMsg structure is set to TRANS_ERR_INV_MSG_ID.

Remarks

The TransportDel function must be implemented by the transport service provider in a DLL registered as a mail service. The Inbox application can load this DLL and call TransportDel.

For the sample service, TransportDel removes the file specified in the MsgPtr structure.