Undelete messages - unmarks any messages that have been marked as deleted.
public void Undelete()
Public Sub Undelete
public:
void Undelete();
Remarks
Represents POP3 RSET command.
Shows how to undelete messages that have been marked as deleted.
using ComponentPro.Net;
using ComponentPro.Net.Mail;
...
// POP3 server information.
const string serverName = "myserver";
const string user = "name@domain.com";
const string password = "mytestpassword";
const int port = 995;
const SslSecurityMode securityMode = SslSecurityMode.Implicit;
// Create a new instance of the Pop3 class.
Pop3 client = new Pop3();
// Connect to the server.
client.Connect(serverName, port, securityMode);
// Login to the server.
client.Authenticate(user, password);
// Delete a mail message with sequence number 1.
client.Delete(1);
// ...
// Undelete all messages.
client.Undelete();
// Close the connection.
client.Disconnect();
Imports ComponentPro.Net
Imports ComponentPro.Net.Mail
...
' POP3 server information.
Const serverName As String = "myserver"
Const user As String = "name@domain.com"
Const password As String = "mytestpassword"
Const port As Integer = 995
Const securityMode As SslSecurityMode = SslSecurityMode.Implicit
' Create a new instance of the Pop3 class.
Dim client As New Pop3()
' Connect to the server.
client.Connect(serverName, port, securityMode)
' Login to the server.
client.Authenticate(user, password)
' Delete a mail message with sequence number 1.
client.Delete(1)
' ...
' Undelete all messages.
client.Undelete()
' Close the connection.
client.Disconnect()