public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport() { ListofBooks2 rpt = new ListofBooks2(); rpt.Site = this.Site; return(rpt); }
private void crystalReportViewer1_Load(object sender, EventArgs e) { LibDataSet context = new LibDataSet(); LibDataSetTableAdapters.BooksTableAdapter b = new LibDataSetTableAdapters.BooksTableAdapter(); b.Fill(context.Books); ListofBooks2 cr = new ListofBooks2(); cr.SetDataSource(context); crystalReportViewer1.ReportSource = cr; }