• Post Reply Bookmark Topic Watch Topic
  • New Topic

Changing background color of a JTable row.

 
Shivaji Bhosale
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I went thr code for changing color for a cell in a table at,
Cell Selection

On the similar grounds, based on the value in say n-th cell,
I am planning to change the color for that complete row.
But somehow I am not getting success into it. My Datatype of each column is String.
Key Steps are,

I am having CustomTableCellRenderer.java as,
 
Paul Stevens
Ranch Hand
Posts: 2823
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try just setting background and return (this) remove the cell stuff.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!