Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Set the color of a row in a JTable

ellias2007Jul 29 2011 — edited Jul 30 2011
Hi all,
i need to set the color of a row (or simply a cell) in a JTable to a specific color,
i read these pages :

http://stackoverflow.com/questions/1057710/how-to-set-the-colour-of-my-1st-row-in-my-jtable-to-yellowor-any-colour
http://www.roseindia.net/java/example/java/swing/SadingRows.shtml
http://stackoverflow.com/questions/3875607/change-the-background-color-of-a-row-in-a-jtable
http://www.codeguru.com/forum/archive/index.php/t-34478.html
http://www.thatsjava.com/java-swing/16549/

and many many links like these ... all are HARD and too complicated ..
What i need is tooooo simple : simply pick some Row and then set its color to red for example ...
CAN you help me Please ....

i need the simplest possible code

Many thanks
This post has been answered by camickr on Jul 30 2011
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 27 2011
Added on Jul 29 2011
8 comments
11,242 views