Hello -
You dont need to open/close conn with Data Adapater; try this:
protected DataTable EmployeeDetails()
{
string id = IDEmployee;
SqlDataAdapter dad = new SqlDataAdapter("GetEmployeeDetails", con);
dad.SelectCommand.CommandType = CommandType.StoredProcedure;
dad.SelectCommand.Parameters.Add("@ID", SqlDbType.NVarChar).Value = id;
DataTable total = ds.Tables["MST_Employee"];
dad.Fill(total, "MST_Employee");
return total;
}
Thanks,
Kuthuparakkal