Stack trace not leading to exceptions

T

Todd

Hello,

As before, the direct output of my program is on a system from which I
can not access the internet, nor can the data be easily transferred.
With that limitation, I am still hopeful that someone may have an idea
as to how I can track down the root of the exceptions that I get.

My program throws both NullPointerException and ClassCastExecption
from thread "AWT-EventQueue-0" showing trace for methods from
javax.swing, java.util and java.awt, but not to any of my methods.

Is there a way to determine where the exception is originating in my
code?

The program is generating and disposing of many progress bars as it
analyzes the problem it is working upon, while maintaining three other
JFrame's, when these exceptions occur. The program does not stop and
the exceptions are thrown repeatedly.

Any help is appreciated,
Todd
 
J

John B. Matthews

T

Todd

<4ae78a30-7a05-4758-9db1-42b879e77...@b38g2000prf.googlegroups.com>,
Are you updating your GUI from a thread other than AWT-EventQueue-0? In
general, Swing is not thread safe:

Each progress bar is in it's own thread, otherwise I never saw any
progress. I will read the information in the links you provided
before I make more comments.

Thanks
 
L

Lew

Todd said:
Each progress bar is in it's [sic] own thread, otherwise I never saw any
progress.

That is wrong. GUI updates *must* happen on the EDT.

java.awt.EventQueue.invokeLater()
javax.swing.SwingWorker
 
T

Todd

Thanks John and Lew. I made an attempt to use the SwingWorker, but
must have used it incorrectly as I am still experiencing exceptions.

From the statement:
GUI updates *must* happen on the EDT.

I believe that I must have to refactor my analysis class to not call
any progress bars, but I don't know how to do so with multi-embedded
loops, each with analysis sections and each with progress bars. Any
ideas?

p.s. I apologize again for not having code available and very much
appreciate your efforts considering the lack.
 
L

Lew

Todd said:
Thanks John and Lew. I made an attempt to use the SwingWorker, but
must have used it incorrectly as I am still experiencing exceptions.

From the statement:


I believe that I must have to refactor my analysis class to not call
any progress bars, but I don't know how to do so with multi-embedded
loops, each with analysis sections and each with progress bars. Any
ideas?

I repeat:
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,228
Members
46,818
Latest member
SapanaCarpetStudio

Latest Threads

Top