Java gui help!!!
Hi am working on a chat gui using java.
the problem is am able to retrieve a list my friends from my xmpp server and display it in the form of text in the textbox of my client gui.
now i want to actually display them as button so that i can use actionlistener on click of the button.
i want this list of buttons to be added automatically as my friends on the server add up.
such that on click of the corresponding button i should get a private window where i can one-one chat ..
any suggestions in this regard is highly appreciated.
Re: Java gui help!!!
It should be fairly easy for you to change the code that adds to the textbox into code that adds a new button.
I would make it a method that takes whatever data you think the button/action listener needs and returns a button which can then be added to the container.