private void btnPrint_Click(object sender, EventArgs e) { if (bsHourData.DataSource != null) { HourDataReport report = new HourDataReport((DataTable)bsHourData.DataSource); report.Export(); } }