msn-messenger

DOTMsn is not firing the SingedIn event


I have just started building a app using “XihSolutions.DotMSN.dll” version: 2.0.0.40909,

My problem is that it is not firing the “Nameserver_SignedIn” event. Not sure if I am doing something wrong. your help will be really helpful.

void Nameserver_SignedIn(object sender, EventArgs e) { throw new Exception("User Signed In"); }

    private string message = string.Empty;
    void NameserverProcessor_ConnectionEstablished(object sender, EventArgs e)
    {

        message = "Connected";
        SetMessage();

    }

    void SetMessage()
    {
        if (tbMessage.InvokeRequired)
           tbMessage. Invoke(new ThreadStart(SetMessage));
        else
        tbMessage.Text += Environment.NewLine+ message; 
    }

    private void btnSingIn_Click(object sender, EventArgs e)
    {
        if (messenger.Connected)
        {
           // SetStatus("Disconnecting from server");
            messenger.Disconnect();
        }

        // set the credentials, this is ofcourse something every DotMSN program will need to
        // implement.
        messenger.Credentials.Account = tbUserName.Text;
        messenger.Credentials.Password = tbPwd.Text;

        // inform the user what is happening and try to connecto to the messenger network.                
        //SetStatus("Connecting to server");
        messenger.Connect();

    }

Solution

  • You might use MSNPSharp instead - DotMSN is old and may not support the current MSN protocol. There link is here:

    http://code.google.com/p/msnp-sharp/