我总是在这段代码中得到一个错误“方法'Fill'没有重载需要2个参数”。我在这里使用 2tables 加入。请帮我
private void button1_Click(object sender, EventArgs e)
{
DataSet1TableAdapters.DataTable1TableAdapter apter = new DataSet1TableAdapters.DataTable1TableAdapter();
DataSet1.DataTable1DataTable table = new DataSet1.DataTable1DataTable();
apter.Fill(table,textBox1.Text);
ReportDataSource NewDataSource = new ReportDataSource("DataSet1", (DataTable)table);
this.reportViewer1.LocalReport.DataSources.Clear();
this.reportViewer1.LocalReport.DataSources.Add(NewDataSource);
this.reportViewer1.LocalReport.Refresh();
this.reportViewer1.RefreshReport();
}
}
}