ImapConnected Event
Occurs when the connection with the server is successfully established.

Namespace: MailBee.ImapMail
Assembly: MailBee.NET (in MailBee.NET.dll) Version: 11.2.0 build 590 for .NET 4.5
Syntax
public event ConnectedEventHandler Connected

Value

Type: MailBeeConnectedEventHandler
Remarks
This event indicates successful completion of the connection procedure, while SocketConnected event (occurs before Connected) indicates the connection request from MailBee was accepted by the server, and the IMAP4 connection procedure will now begin.
Examples
This sample uses Connected event to report the successful connection status into console.
using System;
using MailBee;
using MailBee.ImapMail;

class Sample
{
    // Connected event handler.
    private static void OnConnected(object sender, ConnectedEventArgs e)
    {
        Console.WriteLine("Successfully connected to the server.");
    }

    // The actual code.
    static void Main(string[] args)
    {
        Imap imp = new Imap();

        // Subscribe to Connected event.
        imp.Connected += new ConnectedEventHandler(OnConnected);

        imp.Connect("imap.domain.com");
        imp.Disconnect();
    }
}
See Also