• Post Reply Bookmark Topic Watch Topic
  • New Topic

Urgent: JTable cell listening to mouseClicked???  RSS feed

 
achana chan
Ranch Hand
Posts: 277
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi.
I've a JTable with individual cell selection enabled.
I would like selected cells to listen to mouse clicked events. WHen a user clicks on a cell, a new JFrame pops up.
With my current code, *all* cells are listening to the mouseClicked event. This is wrong. Ideally I would like to use something like this, but I can't get and test colIndex and rowIndex values properly:

I haven't been able to get some clear, concrete answers, I would really appreciate how to do this properly with code samples if at all possible.
Here is my code snippet from a much bigger program, sorry for the size of it.

Please lend a hand if you can.
TIA :-)
 
achana chan
Ranch Hand
Posts: 277
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, works fine now.
I was close.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!