Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

SWT question

 
igwe kalu kalu ogba
Ranch Hand
Posts: 133
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello, I've built a SWT browser. I'm calling it from a Swing application using new Browser("url"). The problem I have is this, it works the first time I call it but after that , I get an Invalid Thread Access exception. Any thoughts on how to fix this? I want to be able to call as many Browsers as I choose by pressing a button on my swing app. Thanks.
 
Scott Delap
author
Ranch Hand
Posts: 73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Assuming your thread issues are coming from the SWT side I would guess you are trying to access a SWT component from a thread that isn't the UI thread.

Scott Delap
ClientJava.com
Desktop Java Live
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic