コード例 #1
0
        public virtual CrystalDecisions.CrystalReports.Engine.ReportDocument CreateReport()
        {
            PrintExamWithStudAns rpt = new PrintExamWithStudAns();

            rpt.Site = this.Site;
            return(rpt);
        }
コード例 #2
0
        private void btn_Print_Click(object sender, EventArgs e)
        {
            PrintExamWithStudAns r = new PrintExamWithStudAns();

            //PrintExamWithStudAnsV2 r = new PrintExamWithStudAnsV2();
            if (int.TryParse(txt_ExamNo.Text, out _) && int.TryParse(txt_StdID.Text, out _))
            {
                r.SetParameterValue("@examNo", txt_ExamNo.Text);
                r.SetParameterValue("@stdID", txt_StdID.Text);
                crystalReportViewer.ReportSource = r;
            }
        }