ASP.net
Awesome
Learn
Forum
Buy
Demos
Sign In
☾
☀
Switch to
Dark
Light
Mode
this site works best with javascript enabled
Ask Question
How change color of row grid without RowClassClientFormat ?
Title:
B
I
{code}
?
I want to change color row depending on its data By data of row have colum color code which store hex code color eg."#f5acb0","#b2a6f5","#acf5ea","#f5f1a7","#f5caab", ... I 'd to generate it to tr tag such as < tr style="background-color:#f5acb0" class="awe-row"> Pls suggest me I read this link http://aspnetawesome.com/forum/question/822/change-the-color-and-the-height-of-the-grid-rows-depending-on-its-data But it use class that I'd to use style
Save Changes
Cancel
nutfergie
asked at 07 Dec 2017
Answers
B
I
{code}
?
without RowClassClientFormat you could handle the `aweload` event and add it manually: $grid.on('aweload', function(){ $grid.each('.awe-row', function(i, el){ $(el).css('color', 'red'); // or .css('color', $(el).data('model').Color)); }); });
Save Changes
Cancel
Omu
answered at 07 Dec 2017
thx for suggestion
at 07 Dec 2017
nutfergie
please
Sign In
to leave an answer
By accessing this site, you agree to store cookies on your device and disclose information in accordance with our
cookie policy
and
privacy policy
.
OK