You need to add your JList (or any component) to a JScrollPane. Easiest way to do this is to pass your component to the JScrollPane’s constructor. You then add the JScrollPane to your component hierarchy (instead of adding your JList).
JScrollPane scrollPne = new JScrollPane(mylist);
panel.add(scrollPane);
Monday, March 23, 2009
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment