The following code will not work:
protected void QueryPaneResults_RowCommand(object sender, GridViewCommandEventArgs e)
{
if (e.CommandName == "SelectionData")
{
int index = Convert.ToInt32(e.CommandArgument);
GridViewRow row = QueryPaneResults.Rows[index];
Label1.Text = row.Cells[1].Text;
}
}
Does anybody know why this causes the following error:
Specified argument was out of the range of valid values.
Parameter name: index

New Topic/Question
Reply



MultiQuote






|