Got a really annoying problem; Ive got a JList which I want to add strings to. When I add one string everything works fine but when I want to add two or more strings nothing shows up in the JList. The code for adding the strings is:
Never had this problem with JLists before ... any thoughts are welcome. Thanks in advance.
I had some similar problems using Strings in JLists, so I wrote a class that only uses Strings with JLists that extends JList:
I guess I should have commented it, but the method names are self-explanitory. There are methods for adding Strings to the JList that allow repeat values or that don't allow them. This code works, but I don't know how efficiently. [ October 18, 2004: Message edited by: Matthew Taylor ]