I have a JEditorPane and an associated CaretListener.
I'd like to change the text of the JEditorPane when some condition in the
CaretListener is met.
This gives an Exception, not to mutate from within a Listener.
How can you solve this?
thanx
nidi
ak - 05 Dec 2003 07:03 GMT
> I'd like to change the text of the JEditorPane when some condition in the
> CaretListener is met.
> This gives an Exception, not to mutate from within a Listener.
You make the changes from wrong thread.
Do it thru SwingUtilities.invokeLater();
--
____________
http://reader.imagero.com the best java image reader.