RemoveEmail method: MCFGetMail class
Syntax
RemoveEmail(user, password, server, node, UID list)
Description
Based on values in the unique identifier list, RemoveEmail deletes emails from the user account on the mail server. It is important to delete emails from the mail server once they are read into PeopleSoft. If you do not delete emails from the mail server after they are read into PeopleSoft, the rowset contains the same collection of email the next time you retrieve email from the mail server.
Parameters
| Parameter | Description |
|---|---|
|
user |
The user name on the mail server, such as “support” or “john_doe”. |
|
password |
The password associated with the specified user name. |
|
server |
The name of the mail server handling the specified user account. |
|
node |
The Integration Broker node on which the request runs. |
|
UID list |
The UID list contains the unique identifier values for the emails that need to be deleted from the mail server. The list can contain multiple values separated by a space. |
Note:
If the value of any of these parameters is null, the method uses default values stored on the specified node. If the node is not specified, the Integration Broker returns an error.
Returns
A Boolean value, indicating the status of the deletion process. If the email has been successfully deleted, this method returns True. Otherwise the method returns False.
Example
Local MCFGetMail &GM;
Local boolean &del_status;
Local string &uid_list = "";
Local string &msg_str;
If (&uid_list <> "") Then
&del_status = &GM.RemoveEmail(&user, &password, &server, &ibnode, &uid_list);
&msg_str = "Email(s) deleted from the Mail Server with UID = " | &uid_list;
MessageBox(0, "", 0, 0, &msg_str);
End-If;
Related Topics