Hi friend,
This below code may help you...
DataTable dt4 = new DataTable();
dt4.Columns.Add("Eid");
dt4.Columns.Add("Emp_Name");
dt4.Columns.Add("uname");
dt4.Columns.Add("Pwd");
foreach (GridViewRow row in Gv.Rows)
{
dr3 = dt4.NewRow();
Label Eid = (Label)row.FindControl("lblEid");
TextBox Ename = (TextBox)row.FindControl("txtEmpname");
TextBox Uname = (TextBox)row.FindControl("txtUname");
TextBox pwd = (TextBox)row.FindControl("txtPwd");
dr3[0] = Eid.Text;
dr3[1] = Ename.Text;
dr3[2] = Uname.Text;
dr3[3] = pwd.Text;
dt4.Rows.Add(dr3);
}
dr3 = dt4.NewRow();
dt4.Rows.Add(dr3);
dt.Clear();
Session.Remove("dt");
dt = dt4.Copy();
Session["dt"] = dt4;
Gv.DataSource = dt4;
Gv.DataBind();