public void deselect()
{
dl.stu_id = Convert.ToInt16(Session["Stu_id"]);
DataTable dt = new DataTable();
dt = bl.exam_disable(dl);
foreach (System.Data.DataRow row in dt.Rows)
{
foreach (GridViewRow gr in GridView1.Rows)
{
string s1 = row["Exam_id"].ToString();
Label l2 = (Label)GridView1.Rows[gr.RowIndex].FindControl("Label3");
LinkButton l1 = (LinkButton)GridView1.Rows[gr.RowIndex].FindControl("linkselect");
if (s1 == l2.Text)
{
l1.Enabled = false;
}
}
}
}
public void retake()
{
foreach (GridViewRow gr in GridView1.Rows)
{
LinkButton l3 = (LinkButton)GridView1.Rows[gr.RowIndex].FindControl("lnkretake");
LinkButton l1 = (LinkButton)GridView1.Rows[gr.RowIndex].FindControl("linkselect");
if (l1.Enabled == true)
{
l3.Enabled = false;
}
else
{
l3.Enabled = true;
}
}
}
{
dl.stu_id = Convert.ToInt16(Session["Stu_id"]);
DataTable dt = new DataTable();
dt = bl.exam_disable(dl);
foreach (System.Data.DataRow row in dt.Rows)
{
foreach (GridViewRow gr in GridView1.Rows)
{
string s1 = row["Exam_id"].ToString();
Label l2 = (Label)GridView1.Rows[gr.RowIndex].FindControl("Label3");
LinkButton l1 = (LinkButton)GridView1.Rows[gr.RowIndex].FindControl("linkselect");
if (s1 == l2.Text)
{
l1.Enabled = false;
}
}
}
}
public void retake()
{
foreach (GridViewRow gr in GridView1.Rows)
{
LinkButton l3 = (LinkButton)GridView1.Rows[gr.RowIndex].FindControl("lnkretake");
LinkButton l1 = (LinkButton)GridView1.Rows[gr.RowIndex].FindControl("linkselect");
if (l1.Enabled == true)
{
l3.Enabled = false;
}
else
{
l3.Enabled = true;
}
}
}

