• 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

JTable ListSelectionListener

 
Ranch Hand
Posts: 476
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have three JTables stacked one on the top of other. Only lower JTable has horizontal scroll bar and listener is attached to it. When this scroll bar is scrolled, the other two top tables scroll as well:


However, when I use arrow keys to move within the table the listener no longer works because I am not using scroll bar. Now I got another listener from sun's website that detects when table is being scrolled with arrow and I get the current column selected, but how do I apply this information to other two tables?



thanks,
Alex

[ April 04, 2005: Message edited by: Alex Kravets ]

[ April 04, 2005: Message edited by: Alex Kravets ]
[ April 04, 2005: Message edited by: Alex Kravets ]
 
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
don't know if this will work in JTables, but worth a try
(the 'pad' part is just to trigger the horizontal scrollbar)

 
All of life is a contant education - Eleanor Roosevelt. Tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic