views:

44

answers:

1

how to get the position /index of checkbox placed inside gridview

                GridViewRow headerrow=GrdDynamicControls.HeaderRow;
                TableCell tb = headerrow.Cells[i];
                string strheaderrow = tb.Text;

                if (strheaderrow.Contains( strColumnName))
                {
                 bool val = ((CheckBox)GrdDynamicControls.Rows[i].FindControl("chkStatus")).Checked;
                }

how to get this checkbox index?/?

any help pls..

A: 

You can use Event Args e

e.Item.ItemIndex

it will return an integer

Hope this will help

Hiyasat