rowIndex in GetRowClass - possible?

  1. #1

    rowIndex in GetRowClass - possible?

    is it possible to get the rowIndex in my gridview getrowclass
    
    
    
    <GetRowClass Handler="var rowIndex;if (!Ext.isEmpty(record.data.Comments)){if(!record.newRecord){rowParams.body = comments(''+ rowIndex +'Comments/Notes: ' + record.data.Comments + ''); return 'x-grid3-row-expanded' ;}}return 'x-grid3-row-collapsed';" />
  2. #2

    RE: rowIndex in GetRowClass - possible?

    Hi,

    GetRowClass is called with the following argumets


    record : Record
    The Ext.data.Record corresponding to the current row
    index : Number
    The row index
    rowParams : Object
    A config object that is passed to the row template during rendering that allows customization of various aspects of a body row, if applicable. Note that this object will only be applied if enableRowBody = true, otherwise it will be ignored. The object may contain any of these properties:
    body : String
    An HTML fragment to be rendered as the cell's body content (defaults to '').
    bodyStyle : String
    A CSS style string that will be applied to the row's TR style attribute (defaults to '').
    cols : Number
    The column count to apply to the body row's TD colspan attribute (defaults to the current column count of the grid).
    store : Store
    The Ext.data.Store this grid is bound to


    Also you can always determine an index using a record
    store.indexOf(record)
  3. #3

    RE: rowIndex in GetRowClass - possible?

    once again - perfect - thanks!

Similar Threads

  1. [CLOSED] [1.0] Access to record by rowIndex
    By edigital in forum 1.x Legacy Premium Help
    Replies: 10
    Last Post: Apr 11, 2011, 12:59 PM
  2. [CLOSED] How to get gridpanel's rowIndex in the example below?
    By deejayns in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Jan 25, 2011, 1:51 PM
  3. [CLOSED] Get the rowIndex of the selected row
    By 78fede78 in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Jan 21, 2011, 12:44 PM
  4. [CLOSED] get rowindex for grid
    By idrissb in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Feb 09, 2010, 3:20 PM
  5. Combo - Populate with rowindex values
    By Tbaseflug in forum 1.x Help
    Replies: 1
    Last Post: Sep 21, 2009, 11:25 AM

Posting Permissions