• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

getting focus out of jTable

 
Ranch Hand
Posts: 125
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have my booking details beneath the JTable. When user presses TAB on last row, last col i want to take the foucs out of JTable to the reservation textfiled.
someone pls let me know the api for that
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well there are KeyListeners that you can use, but there is also ListSelectionListener. You need to create a class that implements one of these interfaces, provide the necessay method, get the Jatable make sure they are already on the last row, if it is, call the requestFocus() method of the component you want to grab the focus.
That is the overview, the specific details you will need to look at the api to get.
If not, then don't implement that, you won't get docked points if you don't have it tab out of the JTable.
Mark
 
Reshma Das
Ranch Hand
Posts: 125
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks Mark iam not sure how to implement it iam going to ignore it.
 
reply
    Bookmark Topic Watch Topic
  • New Topic