• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JButton in JTable

 
Sven Mari�n
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys,

Does any of you know how I can put a clickable JButton in a JTable ? I succeed in adding the JButton as a CellRenderer in my JTable, but it doesn't seem to react to ActionEvents...
 
Mark Spritzler
ranger
Sheriff
Posts: 17278
6
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think it is a good idea to try and figure out how to add a JButton to a Jtable as a way for you to learn. However, it isn't really necessary for you to do this for the assignment. So if you get frustrated and can't figure it out, don't feel bad.

Where do you add the ActionListener code?

Mark
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic