Exemplo n.º 1
0
        public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport()
        {
            rptCustomerList rpt = new rptCustomerList();

            rpt.Site = this.Site;
            return(rpt);
        }
Exemplo n.º 2
0
        protected void Show_Click(object sender, EventArgs e)
        {
            if (Session["report"] == null)
            {
                CustomerTableAdapters.CustomersTableAdapter da = new CustomerTableAdapters.CustomersTableAdapter();

                Customer ds = new Customer();
                Customer.CustomersDataTable dt = (Customer.CustomersDataTable)ds.Tables["Customers"];
                da.Fill(dt);

                rpt = new rptCustomerList();
                rpt.SetDataSource(ds);
                CrystalReportViewer.ReportSource = rpt;


                Session.Add("report", rpt);
            }
        }