Provides data for the Imap.EndMailboxAdd, Imap.EndList, and Imap.Mailbox events.
Object Model
Syntax
| Visual Basic (Declaration) | |
|---|
Public Class MailboxEventArgs
Inherits EndEventArgs |
| Managed Extensions for C++ | |
|---|
public __gc class MailboxEventArgs : public EndEventArgs |
| C++/CLI | |
|---|
public ref class MailboxEventArgs : public EndEventArgs |
Example
The following example demonstrates asynchronously creating a new mailbox.
| Visual Basic | Copy Code |
|---|
private void AsynchronousMailboxCreateTest()
{
' Login to the server.
Imap1.Login(Server, User, Pass)
' Begin to asynchronously create a new mailbox. When
' complete, the Imap.EndMailboxAdd event will be raised.
Imap1.Mailboxes.BeginAdd("MyNewMailbox", Nothing)
}
Private Sub Imap1_EndMailboxAdd(ByVal sender As Object, ByVal e As Dart.PowerTCP.Mail.MailboxEventArgs) Handles Imap1.EndMailboxAdd
If e.Exception Is Nothing Then
Debug.WriteLine("New mailbox " + e.Mailbox.Name + " created.")
Else
Debug.WriteLine("Exception received: " + e.Exception.Message)
End If
End Sub |
| C# | Copy Code |
|---|
private void AsynchronousMailboxCreateTest()
{
// Login to the server.
imap1.Login(Server, User, Pass);
// Begin to asynchronously create a new mailbox. When
// complete, the Imap.EndMailboxAdd event will be raised.
imap1.Mailboxes.BeginAdd("MyNewMailbox", null);
}
private void imap1_EndMailboxAdd(object sender, Dart.PowerTCP.Mail.MailboxEventArgs e)
{
if(e.Exception == null)
Debug.WriteLine("New mailbox " + e.Mailbox.Name + " created.");
else
Debug.WriteLine("Exception received: " + e.Exception.Message);
} |
Remarks
Inheritance Hierarchy
Requirements
Target Platforms: Microsoft .NET Framework 2.0
See Also