Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_Related Related Topics sp_TopicIcon
Colorize td after change
Tags: color
16/08/2011
11:08
Avatar
KevinB
Member
Members
Forum Posts: 6
Member Since:
16/08/2011
sp_UserOfflineSmall Offline

Hi,

i colorize my treegrid in the gridComplete function:

gridComplete: function () {
               for (var i = 0; i < rowsToColor.length; i++) {
                    
                    if(rowsToColor[i]%2 == 0)
                    {
                      $("#" + rowsToColor[i]).find("td").css("background-color", "blue");
                    }

                    var ta= $("#" + rowsToColor[i]).find("td").eq(4).html();
                    if (ta== "OK") {
                        $("#" + rowsToColor[i]).find("td").eq(4).css("background-color", "green");
                    }

                    var status = $("#" + rowsToColor[i]).find("td").eq(2).html();
                    if (status == "NOK") {
                        $("#" + rowsToColor[i]).find("td").eq(2).css("background-color", "red");
                    }
                }
             }

the rowsToColor-Array is filled in

function rowColorFormatter(cellValue, options, rowObject) {
            rowsToColor[rowsToColor.length] = options.rowId;
            return cellValue;
          }

which is called by a formatter

formatter: rowColorFormatter

That works!

But after i change a value, the color stay the same, because i don't know, which function is called after a Cell-Change.

I tried it with

afterSubmitCell: function(serverresponse, rowid, cellname, value, iRow, iCol){
               alert("huhu");        
             }

but that event doesn't fire.

Does somebody have any idea?

Thank You.

17/08/2011
13:41
Avatar
KevinB
Member
Members
Forum Posts: 6
Member Since:
16/08/2011
sp_UserOfflineSmall Offline

Hm, can somebody tell me the Event that is triggered after an inlineCell-Edit?

Then i will try again 🙂

26/08/2011
17:22
Avatar
KevinB
Member
Members
Forum Posts: 6
Member Since:
16/08/2011
sp_UserOfflineSmall Offline

Hm, i've found a workaround, that is not verry pretty!

i can click in the Box, where the actual page-number is, and hit "return". so the grid is reloading, and the colors are right. 🙂

ok, NOT PRETTY! 🙂

so i need your help!

THX,

Kevin

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
39 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information