|
I have this small problem. When I try to dinamically add new elements (String array) to JList (through Listmodel - strange actually that JList doesn't have such fucntion as addElement or smth.) it doesn't seem to be working as it should - I mean all I get is only one Element with some content that probably refers to String array. Or not. Anyway, if someone could help me on this I'd be very grateful.
And another problem :) I have a function that uses Random object (Something like Random r = new Random(); r.nextInt(40)). But when I call this function several times using cycle it returns the same values. But! If I call this function simply by writing it several times the result is different. How can that be? |