Если я понимаю, что вы спрашиваете ... вам не нужно цикл ...
protected void GridView1_RowCommand(Object sender, GridViewCommandEventArgs e){
if (e.CommandName == "thiscommandname") {
int index = Convert.ToInt32(e.CommandArgument);
GridViewRow selectedRow = ((GridView)e.CommandSource).Rows[index];
//and then for example...
string rowText = (LinkButton)selectedRow.Cells[0].Controls[0]).Text;}
}