aditya immadi

aditya immadi

  • NA
  • 215
  • 22.1k

The type 'System.Data.SqlClient.SqlDataReader' has no constr

Apr 25 2016 4:11 AM
Hai all i tried something like this
 
[HttpPost]
public ActionResult editpersonaldetails(tb_userpersonaldata obj)
{
DataTable dt = new DataTable();
Guid userid = (Guid)Session["userid"];
string s = "select * from tb_userpersonaldata where userid='" + userid + "'";
SqlConnection con = new SqlConnection();
SqlCommand cmd = new SqlCommand(s, con);
con.Open();
SqlDataReader dr;
dr = new SqlDataReader();
dt.Load(dr);
dr.Close();
con.Close();
 
can any one  
return View();
}
 
bbut it says The type 'System.Data.SqlClient.SqlDataReader' has no constructor ..i m not able to find the bug...can any suggestions??
 
TIA 
 

Answers (2)