Jim Cobban wrote:
I have a program which reads spreadsheets using the HSSF event model under Swing. The issue I have is that I need to periodically release control to Swing so it can permit other activities, such as repainting the window, to take place. The standard way of doing this is to implement Runnable and perform the long-running task in the run method, which is actually called by Swing and reschedules itself with SwingUtilities.invokeLater(this) as long as there is more work to be done. But in the HSSF event model all of the work is done in a single call to HSSFEventFactory.processEvents, and I cannot see an easy way to interrupt this process to give control back to Swing.Create a model which surrounds HSSF and communicates with your GUI via an event when its done. Run that model thingy in another
Jim Cobban [EMAIL PROTECTED]
34 Palomino Dr.
Kanata, ON, CANADA
K2M 1M1
+1-613-592-9438
thread, synchronize access to it (or launch seperate threads). Wrapping the long running task is something I view as the application developer's area of concern.
-Andy
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
