Color of Selected Row
Color of Selected Row
ngungo
Posts: 64Questions: 23Answers: 2
How do I change color of selected row?
I searched but could not find it
I also tried this but it doesn't work.
I need a hint. Thanks!
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) {
if ($(nRow).hasClass("selected")) $(nRow).css('color', 'white');
// if ($(nRow).hasClass("active")) $(nRow).css('color', 'white');
},
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
The faster reliable way to do that is by CSS.
tr.selected{
color: #ffffff;
}
if you don't have access to CSS you can also do:
Hi DirceuNazareth,
I am talking about selecting a row for editing.
I have access to CSS and
does not work. Then I tried the script you gave. It does not work either.
Hi DirceuNazareth,
I know why it does not work, in my case. I need to work it out then get back here to let you know. Sorry!
Everything is working now.
thank you for the feedback