Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    How to set background color of a row in the treegrid?

    Hello,

    I have a treegrid and i need to set a background color of the rows that are open.

    So i am using the following code:

    Code:
    for ( i = 0; i < menuTree.data.root.children.length; i++ )
    {
          if ( menuTree.data.root.children[i].isOpen )
          {
                menuTree.data.root.children[i].setBackgroundColor( '#f3f3f3' );
          }
    }
    Unfortunately it is not working. Is there another way to do this or am i doing something wrong?

    #2
    See TG.getBaseStyle and TG.getCellStyle. You are likely to override one of those and determine your desired style based on the isOpen property of the record.

    Comment

    Working...
    X