This is a migrated thread and some comments may be shown as answers.

DataBind find an earlier row item

0 Answers 35 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Scott
Top achievements
Rank 1
Scott asked on 30 Mar 2014, 05:38 PM
I would like to find & compare an earlier row item during the dataBind on my grid.  Here's a partial code I'm hoping to complete:

protected void RadGridX_ItemDataBound(object sender, GridItemEventArgs e)
{
    if (e.Item is GridDataItem)
    {
        GridDataItem item = e.Item as GridDataItem;
        if (item["Name"].Text == "RowIWant")
        {
            foreach(string colName in colNames)
            {
                //get this row's value
                int thisValue = Convert.ToInt32(item[colname].Text);

                // get the value from the RowToCompare
                int earlierValue = ???

            }
        }
    }
}



No answers yet. Maybe you can help?

Tags
Grid
Asked by
Scott
Top achievements
Rank 1
Share this question
or