asp.net - Change the color of a row in Gridview when Checkbox is checked -


i have datagridview template field of checkboxes each row in asp.net app. running code in pageload event. when person checks box on row, rows backcolor or forecolor should highlighted yellow, it's not working. here code:

foreach (gridviewrow row in gvsummary.rows) {     checkbox cb = (checkbox)row.findcontrol("chkitemselector");     if (cb != null && cb.checked)     {         row.backcolor = color.yellow;     } } 

how can make work?

if want in client side , there no need page_load event . instead should use javascript or better suggestion jquery

look @ these :


Comments

Popular posts from this blog

delphi - How to convert bitmaps to video? -

jasper reports - Fixed header in Excel using JasperReports -

python - ('The SQL contains 0 parameter markers, but 50 parameters were supplied', 'HY000') or TypeError: 'tuple' object is not callable -