Exception in thread "AWT-EventQueue-0" java.lang.IllegalStateException: Not on FX application thread;

Joined
Jul 19, 2021
Messages
2
Reaction score
0
Hi Team,
Im using SwingUtilities.invokeLater() under that called one method to set text to button in ubuntu linux but not getting set, facing exception

Exception in thread "AWT-EventQueue-0" java.lang.IllegalStateException: Not on FX application thread; currentThread = AWT-EventQueue-0

Tried workarounds:
1.Tested by calling SwingUtilities.invokeLater() inside background [SwingWorker Class] thread still the result occurs same.Returns above exception as mentioned
2. If i use Platform.runLater() in windows it works fine,but linux gets freeze.
3.Tested by calling Platform.runLater() inside background/worker [SwingWorker Class ] thread still the UI hangs.


Any help would be appreciated..
Thanks in advance

Regards,
Rak
 

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

Forum statistics

Threads
473,982
Messages
2,570,185
Members
46,736
Latest member
AdolphBig6

Latest Threads

Top