SqlConnection con=new SqlConnection();
SqlDataAdapter adap=new SqlDataAdapter("select * from student where Id=-1",con);
DataSet mydataset=n开发者_高级运维ew DataSet();
adap.Fiil(mydataset,"students");
BindingSource mybindingsource=new BindingSource(mydataset,"students");
Now I create a adapter and fiil it a dataset and create a bindingsource with dataset table There is no item in BindingSource.How can I get ColumnNames in my Query from Bindingsource unless use dataset table??
精彩评论