• Post Reply Bookmark Topic Watch Topic
  • New Topic

JButton Click event loses focus and the function behaves arbitrarily  RSS feed

 
Reading B
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have an applet that runs in IE6.0 (Microsoft VM). This Applet contains swing components - buttons. These buttons are created on a button click event.
My problem is after creation of buttons, if I don't move my mouse and click again on a button to invoke the further creation of buttons, the focus moves on to some random button and the click happens on the respective button.
I am not having any clue why this is happening. This works perfectly if I move my mouse and try clicking the same button.
Please let me know your views/code suggestions.
Thanks a lot,
-Rock
 
Dana Hanna
Ranch Hand
Posts: 227
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You'll need to post some code so that we can see what you're working with.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!