Question

Je viens de commencer la construction d'une application en utilisant la version « XihSolutions.DotMSN.dll »: 2.0.0.40909,

Mon problème est qu'il ne se déclenche pas l'événement « Nameserver_SignedIn ». Je ne sais pas si je fais quelque chose de mal. votre aide sera vraiment utile.

Nameserver_SignedIn vide (expéditeur d'objet, EventArgs e)         {             throw new Exception ( "utilisateur connecté");         }

    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();

    }
Était-ce utile?

La solution

Vous pouvez utiliser MSNPSharp à la place - DotMSN est vieux et ne supportent pas le protocole MSN actuel. Il est ici lien:

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

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top