Manning's Countdown to 2014
. Use discount code crdotd14 all month for 50% off every deal.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Swing / AWT / SWT
Joined: Jan 26, 2006
Apr 05, 2009 21:49:07
i have few textfields on my frame. I want to know the textfield name which is currently focused. can someone please help me. How to know the current focused object name.
Joined: Jun 09, 2003
Apr 05, 2009 21:57:14
this will give you the focus owner
Component currentFocusOwner = KeyboardFocusManager.getCurrentKeyboardFocusManager().getFocusOwner();
Component has a getName(), but you would be responsible for setting the name
I agree. Here's the link:
subject: Focuse object
Oracle Certification Site Similar to Javaranch
xml certificate kinds
Prototype and JQuery
* Welcome Larry Aronson
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2013