Exemplo n.º 1
0
        private void btnPrint_Click(object sender, EventArgs e)
        {
            string path = @"Clinica_01.Reports.ClienteReport.rdlc";

            this.reportViewer = new ReportViewer();

            this.reportViewer.LocalReport.DataSources.Add(new ReportDataSource("DataSet2", ListClientes));

            FormReport frmReport = new FormReport(this.reportViewer, path, GetParametersToPrint());

            frmReport.ShowDialog();
        }
Exemplo n.º 2
0
        private void btnPrint_Click(object sender, EventArgs e)
        {
            string path = @"Clinica_01.Reports.AgendaReport.rdlc";

            if (this.reportViewer == null)
            {
                this.reportViewer = new ReportViewer();
            }

            var ListAgenda = AgendaRepositorySQLite.GetAll().ToList <Agenda>();

            this.reportViewer.LocalReport.DataSources.Add(new ReportDataSource("DataSet2", ListAgenda));

            FormReport frmReport = new FormReport(this.reportViewer, path, GetParametersToPrint());

            frmReport.ShowDialog();
        }