3

As question states I want to add more than one table in RDLC report. I have added one table in few reports. But don't know how to add multiple tables in a single report. I am adding tables using objects as DataSource. My database is SQLite.

I found a tutorial to make rdlc using object as datasource here. But that does not say about multiple tables. How to do it?

DhavalR
  • 1,409
  • 3
  • 29
  • 57

1 Answers1

6

you can do this following steps given below ,

1.Create 2 dataset in RDLC file in respect to each table

2.Pass these 2 dataset from your code

ReportDataSource rds = new ReportDataSource("dsChart",ObjectDataSource1);

ReportDataSource rds2 = new ReportDataSource("DataSet1",ObjectDataSource2);

rptViewer.LocalReport.DataSources.Clear();

rptViewer.LocalReport.DataSources.Add(rds);

rptViewer.LocalReport.DataSources.Add(rds2);

moreover you can relate with this tutorial

varsha
  • 1,620
  • 1
  • 16
  • 29