我记得好像是不能直接绑定DataReader的..
得用个BindingSource作个中介..
SqlDataReader sdr=cmd.ExecuteReader();
BindingSource bs=new BindingSource();
bs.DataSource=sdr;
this.DataGridView1.DataSource=bs;
我记得好像是不能直接绑定DataReader的..
得用个BindingSource作个中介..
SqlDataReader sdr=cmd.ExecuteReader();
BindingSource bs=new BindingSource();
bs.DataSource=sdr;
this.DataGridView1.DataSource=bs;