摘要:
//定义一个返回DataTable 的方法private DataTable AA(){ SqlConnection con=new SqlConnection("server=localhost;database=aa;uid=sa;pwd=sa;) con.Open(); DataTable dt=new DataTable(); SqlDataAdapter da=new SqlDataAdapter("select aa from b",con); dt.Clear(); da.Fill(dt); return dt;}static void Main() 阅读全文