Change style of a EnhancedGrid line on "onRowClick" event
I want to change a color of grid line but without 开发者_C百科selecting it. It means I cannot use onStyleRow event as it reacts only for 'selected', 'odd' or 'over' event.
Any ideas?
thx
I found an updateRowStyles(idxRow) function, but no idea how to use it (how to pass syles etc.) and not sure if it will solve my problem
You cant change your style this way:
var layout = [
{ field: 'denumire', name: 'Denumire', width: '200px', height: '25px', styles: "color:red;" },
{ field: 'valoare', name: 'Valoare', width: '252px', styles: "color:red;"}];
or use formatter in layout grid
var layout = [
{ field: 'denumire', name: 'Denumire', width: '200px', height: '25px', formatter: function (value, rowIndex) {
return "<div style='height:110px;text-overflow:ellipsis;color:red;'>"+value+"</div>"
} },
{ field: 'valoare', name: 'Valoare', width: '252px',
formatter: function (value, rowIndex) {
return "<div style='height:110px;text-overflow:ellipsis;color:red;'>"+value+"</div>"
}}];
精彩评论