Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Setting Focus in a Panel, not frame?

 
Salue Lek
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hello all,
I am trying to set focus in a jtextfield that's in a panel. It is not on a frame so it doesn't have a window opened().
thanks,
Salue
 
Cindy Glass
"The Hood"
Sheriff
Posts: 8521
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Components have a requestFocus() method that can be used for this.
 
Salue Lek
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Cindy,
thanks for the reply. I'm trying to figure out where to put the requestFocus() method. Where would I insert that code?
thanks,
Salue
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic