Jan 31

Swing is single thread so you are best to load the data from the ResultSet in a separate thread. And because it is a different thread than Swing’s Event Dispatch Thread you’ll need to ensure each entry to be added to the list is added from the EDT.

The SwingWorker class can be used to handle tasks like this.

Let us know if you’d like to see some example code.

written by objects \\ tags: ,


One Response to “How to load a data from a ResultSet into a JList?”

  1. Bulelani Says:

    i would to see a code example when loading a data from resultSet into a JList

Leave a Reply

You must be logged in to post a comment.