Jump to content

Obter informações a partir de uma listbox...


Hitmanpt
 Share

Recommended Posts

Boas pessoal.... eu tenho os contactos do messenger numa list box...

E eu obtenho os contactos usando este codigo

MessengerAPI.IMessenger objmsgr = new MessengerAPI.MessengerClass();
                    MessengerAPI.IMessengerContacts contacts = (MessengerAPI.IMessengerContacts)objmsgr.MyContacts;

                    foreach (MessengerAPI.IMessengerContact contact in contacts)
                    {
                        if (contact.Status != MessengerAPI.MISTATUS.MISTATUS_OFFLINE)
                        {
                            lboxmsncontacts.Items.Add(contact.FriendlyName);
                        }
                    }

Mas na list box aparece o Nickname da pessoa (o que eu quero que apareca na listbox)

Mas quero que por exemplo quando seleciono algum contacto dessa listbox e carrego num botão queria que me aparece-se o email e nao o nickname

para obter o email usa-se este comando...

contact.SigninName

Alguma ideia»?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

By using this site you accept our Terms of Use and Privacy Policy. We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.