Esempio n. 1
0
 private void CourseWisePrintSelectedButton_Click(object sender, EventArgs e)
 {
     ResultCourseWiseDataSet ds = new ResultCourseWiseDataSet();
     //course
     ResultCourseWiseTableAdapter resultCourseWiseTableAdapter = new ResultCourseWiseTableAdapter();
     resultCourseWiseTableAdapter.FillBy(ds.ResultCourseWiseDataTable, (int)CourseWiseSessionComboBox.SelectedValue, (int)CourseWiseCourseNoComboBox.SelectedValue);
     ReportForm rf = new ReportForm();
     rf.Show();
     bool isTheory = int.Parse(courseList[CourseWiseCourseNoComboBox.SelectedIndex].Course_No) % 2 == 1;
     if (isTheory)
     {
         ResultCourseWiseAllTheoryCR report = new ResultCourseWiseAllTheoryCR();
         report.SetDataSource(ds);
         report.SetParameterValue("DisciplineName", Depertment.DisciplineName);
         report.SetParameterValue("SchoolName", Depertment.SchoolName);
         rf.crystalReportViewer1.ReportSource = report;
     }
     else
     {
         ResultCourseWiseAllSessionalCR report = new ResultCourseWiseAllSessionalCR();
         report.SetDataSource(ds);
         report.SetParameterValue("DisciplineName", Depertment.DisciplineName);
         report.SetParameterValue("SchoolName", Depertment.SchoolName);
         rf.crystalReportViewer1.ReportSource = report;
     }
 }
Esempio n. 2
0
        private void CourseWisePrintAllSessionalButton_Click(object sender, EventArgs e)
        {
            ResultCourseWiseDataSet ds = new ResultCourseWiseDataSet();
            ResultCourseWiseTableAdapter resultCourseWiseTableAdapter = new ResultCourseWiseTableAdapter();
            int isTheory = 0;
            resultCourseWiseTableAdapter.FillAllBy(ds.ResultCourseWiseDataTable, (int)CourseWiseSessionComboBox.SelectedValue, (int)CourseWiseYearComboBox.SelectedValue, (int)CourseWiseTermComboBox.SelectedValue, isTheory);
            ReportForm rf = new ReportForm();
            rf.Show();
            ResultCourseWiseAllSessionalCR report = new ResultCourseWiseAllSessionalCR();
            report.SetDataSource(ds);
            report.SetParameterValue("DisciplineName", Depertment.DisciplineName);
            report.SetParameterValue("SchoolName", Depertment.SchoolName);
            rf.crystalReportViewer1.ReportSource = report;

        }
Esempio n. 3
0
 private void PrintButton_Click(object sender, EventArgs e)
 {
     ResultCourseWiseDataSet ds = new ResultCourseWiseDataSet();
     //course
     ResultCourseWiseTableAdapter resultCourseWiseTableAdapter = new ResultCourseWiseTableAdapter();
     resultCourseWiseTableAdapter.FillBy(ds.ResultCourseWiseDataTable,(int)SessionToolStripComboBox.ComboBox.SelectedValue, (int)CourseNoToolStripComboBox.ComboBox.SelectedValue);
     ReportForm rf = new ReportForm();
     rf.Show();
     if (isTheory)
     {
         ResultCourseWiseAllTheoryCR report = new ResultCourseWiseAllTheoryCR();
         report.SetDataSource(ds);
         rf.crystalReportViewer1.ReportSource = report;
     }
     else
     {
         ResultCourseWiseAllSessionalCR report = new ResultCourseWiseAllSessionalCR();
         report.SetDataSource(ds);
         rf.crystalReportViewer1.ReportSource = report;
     }
 }