File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Swing / AWT / SWT and the fly likes Help me reducing JTABLE loading time.. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Help me reducing JTABLE loading time.. " Watch "Help me reducing JTABLE loading time.. " New topic
Author

Help me reducing JTABLE loading time..

shailesh jamloki
Ranch Hand

Joined: Oct 28, 2004
Posts: 38
Hi my small application loads connected agents with properties in a jtable.
*Connected agents are are some process which are listening to some port.

If I have 30 agents and out of 20 are connected. So I have to load 20 agents in the table.

But when the application loads.. my swing application hangs as it takes time to see if all the agents are connected and then load only connected agents.

Is this possible to load a connected in the jtable as soon as we figure out those are connected. So that swing application do not be in loading state.

and update the jtable successively


Thanks
Shailesh
Agador Paloi
Ranch Hand

Joined: Jan 24, 2006
Posts: 118
It sounds like you may want a seperate worker thread to update the JTable
Mikko Kohtamäki
Ranch Hand

Joined: Dec 13, 2008
Posts: 112
http://java.sun.com/javase/6/docs/api/javax/swing/SwingWorker.html
http://java.sun.com/developer/technicalArticles/javase/swingworker/

doInBackground() handles all connected agents and calls publish(agent) for every connected agent and in process(List<Agent> agents) the connected agent's properties are inserted into table.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Help me reducing JTABLE loading time..
 
Similar Threads
JTable tabbing
Extending JTable
JTable
JTable
JTable Paging