Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Displaying data when window opens

 
Geoff Jefferson
Ranch Hand
Posts: 102
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I am interested in displaying data in a given component (JRadioButton) when the user opens a window such as
a JFrame. Currently I have experimented with windowActivated(), and windowOpened() with some
success. The only problem ( so far ) is that when the user changes the data in the field, then changes to
another sreen in another app ( alt-tab ) and returns, the data reverts back to the original data.

This module is being used to modify data stored on the hard drive.

What is a good way to accomplish this?

Thanks.


 
Rob Camick
Ranch Hand
Posts: 2564
9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I can understand windowActivated refreshing the value, but windowOpened should only be invoked once so it should work.

Post your SSCCE demonstrating the problem.

Of course you can always remove the listener once the code has been executed once.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic