private void button1p_Click(object sender, RoutedEventArgs e) { Windows.CrystalReportViewerWindow wnd = new ePAM.Windows.CrystalReportViewerWindow(); // Change 'OperationalUnitTableAdapter' to appropriate adapter. ePAM.Reports.StrategyDataSetTableAdapters.OperationalUnitTableAdapter adapter = new ePAM.Reports.StrategyDataSetTableAdapters.OperationalUnitTableAdapter(); adapter.Connection.ConnectionString = BusinessLayer.BusinessLayer.GetConnectionString(); adapter.Fill(dataSet.OperationalUnit); // Change 'Operational_Units' to appropriate report. Reports.Print.Operational_Units objReport = new Reports.Print.Operational_Units(); // Change 'dataSet.OperationalUnit' to 'dataSet.***'. objReport.SetDataSource(dataSet); wnd.MyReportViewer.ReportSource = objReport; wnd.MyReportViewer.RefreshReport(); wnd.ShowDialog(); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)