Пример #1
0
        private void pbPrint_Click(object sender, EventArgs e)
        {
            if (dataGridView1.RowCount <= 1)
            {
                return;
            }

            string reportFileName = "SmartMES_SinMyung.Reports.P1FD01_KPI.rdlc";

            string reportParm1 = "조회년도 : ";
            string reportParm2 = "";
            string reportParm3 = "";

            reportParm1 = reportParm1 + cbYYYY.Text + "년도";


            ViewReport_H viewReport = new ViewReport_H();

            viewReport.reportViewer1.ProcessingMode = ProcessingMode.Local;
            viewReport.reportViewer1.LocalReport.ReportEmbeddedResource = reportFileName;

            ReportParameter rp1 = new ReportParameter("ReportParameter1", reportParm1);
            ReportParameter rp2 = new ReportParameter("ReportParameter2", reportParm2);
            ReportParameter rp3 = new ReportParameter("ReportParameter3", reportParm3);

            viewReport.reportViewer1.LocalReport.SetParameters(new ReportParameter[] { rp1, rp2, rp3 });

            ReportDataSource rds = new ReportDataSource("DataSet1", sPKPIBindingSource);

            viewReport.reportViewer1.LocalReport.DataSources.Add(rds);
            viewReport.reportViewer1.LocalReport.Refresh();

            viewReport.ShowDialog();
        }
Пример #2
0
        private void pbPrint_Click(object sender, EventArgs e)
        {
            if (dataGridView1.RowCount <= 1)
            {
                return;
            }

            string reportFileName = "SmartMES_SinMyung.Reports.P1C09_PROD_NG.rdlc";

            string reportParm1 = "생산기간 : ";
            string reportParm2 = "불량항목 : ";
            string reportParm3 = "생산그룹 : ";

            reportParm1 = reportParm1 + dtpFromDate.Value.ToString("yyyy-MM-dd") + " ~ " + dtpToDate.Value.ToString("yyyy-MM-dd");
            reportParm2 = reportParm2 + cbItem.Text;
            reportParm3 = reportParm3 + cbGrp.Text;

            ViewReport_H viewReport = new ViewReport_H();

            viewReport.reportViewer1.ProcessingMode = ProcessingMode.Local;
            viewReport.reportViewer1.LocalReport.ReportEmbeddedResource = reportFileName;

            ReportParameter rp1 = new ReportParameter("ReportParameter1", reportParm1);
            ReportParameter rp2 = new ReportParameter("ReportParameter2", reportParm2);
            ReportParameter rp3 = new ReportParameter("ReportParameter3", reportParm3);

            viewReport.reportViewer1.LocalReport.SetParameters(new ReportParameter[] { rp1, rp2, rp3 });

            ReportDataSource rds = new ReportDataSource("DataSet1", sPProdNgQueryBindingSource);

            viewReport.reportViewer1.LocalReport.DataSources.Add(rds);
            viewReport.reportViewer1.LocalReport.Refresh();

            viewReport.ShowDialog();
        }
        private void pbPrint_Click(object sender, EventArgs e)
        {
            if (dataGridView1.RowCount <= 1)
            {
                return;
            }

            string reportFileName = "SmartMES_SinMyung.Reports.P1B09_DELI_NON.rdlc";

            string reportParm1 = "수주기간 : ";
            string reportParm2 = "거래처/프로젝트/영업담당/현장 : ";
            string reportParm3 = "";

            reportParm1 = reportParm1 + dtpFromDate.Value.ToString("yyyy-MM-dd") + " ~ " + dtpToDate.Value.ToString("yyyy-MM-dd");

            if (string.IsNullOrEmpty(tbSearch.Text.Trim()))
            {
                reportParm2 = reportParm2 + "전체";
            }
            else
            {
                reportParm2 = reportParm2 + tbSearch.Text.Trim();
            }

            reportParm3 = reportParm3 + "";

            ViewReport_H viewReport = new ViewReport_H();

            viewReport.reportViewer1.ProcessingMode = ProcessingMode.Local;
            viewReport.reportViewer1.LocalReport.ReportEmbeddedResource = reportFileName;

            ReportParameter rp1 = new ReportParameter("ReportParameter1", reportParm1);
            ReportParameter rp2 = new ReportParameter("ReportParameter2", reportParm2);
            ReportParameter rp3 = new ReportParameter("ReportParameter3", reportParm3);

            viewReport.reportViewer1.LocalReport.SetParameters(new ReportParameter[] { rp1, rp2, rp3 });

            ReportDataSource rds = new ReportDataSource("DataSet1", sPDeliNonQueryBindingSource);

            viewReport.reportViewer1.LocalReport.DataSources.Add(rds);
            viewReport.reportViewer1.LocalReport.Refresh();

            viewReport.ShowDialog();
        }
Пример #4
0
        private void pbPrint_Click(object sender, EventArgs e)
        {
            string reportFileName = "SmartMES_SinMyung.Reports.P1D03_MAINTENANCE.rdlc";

            string reportParm1 = "점검기간 : ";
            string reportParm2 = "호기/설비명/설비그룹 :";
            string reportParm3 = "";

            reportParm1 = reportParm1 + dtpFromDate.Value.ToString("yyyy-MM-dd") + " ~ " + dtpToDate.Value.ToString("yyyy-MM-dd");

            if (string.IsNullOrEmpty(tbSearch.Text.Trim()))
            {
                reportParm2 = reportParm2 + "전체";
            }
            else
            {
                reportParm2 = reportParm2 + tbSearch.Text.Trim();
            }

            reportParm3 = reportParm3 + "";

            ViewReport_H viewReport = new ViewReport_H();

            viewReport.reportViewer1.ProcessingMode = ProcessingMode.Local;
            viewReport.reportViewer1.LocalReport.ReportEmbeddedResource = reportFileName;

            ReportParameter rp1 = new ReportParameter("ReportParameter1", reportParm1);
            ReportParameter rp2 = new ReportParameter("ReportParameter2", reportParm2);
            ReportParameter rp3 = new ReportParameter("ReportParameter3", reportParm3);

            viewReport.reportViewer1.LocalReport.SetParameters(new ReportParameter[] { rp1, rp2, rp3 });

            ReportDataSource rds = new ReportDataSource("DataSet1", sPMachineRepairQueryBindingSource);

            viewReport.reportViewer1.LocalReport.DataSources.Add(rds);
            viewReport.reportViewer1.LocalReport.Refresh();

            viewReport.ShowDialog();
        }
        private void pbPrint_Click(object sender, EventArgs e)
        {
            string reportFileName = "SmartMES_SinMyung.Reports.P1B11_PURCHASE_TOLL.rdlc";

            string reportParm1 = cbTerm.Text.Substring(2, cbTerm.Text.Length - 2) + " : ";
            string reportParm2 = "가공처/품목명/자재명 : ";
            string reportParm3 = "구 분 : ";

            reportParm1 = reportParm1 + dtpFromDate.Value.ToString("yyyy-MM-dd") + " ~ " + dtpToDate.Value.ToString("yyyy-MM-dd");

            if (string.IsNullOrEmpty(tbSearch.Text.Trim()))
            {
                reportParm2 = reportParm2 + "전체";
            }
            else
            {
                reportParm2 = reportParm2 + tbSearch.Text.Trim();
            }

            reportParm3 = reportParm3 + cbGubun.Text;

            ViewReport_H viewReport = new ViewReport_H();

            viewReport.reportViewer1.ProcessingMode = ProcessingMode.Local;
            viewReport.reportViewer1.LocalReport.ReportEmbeddedResource = reportFileName;

            ReportParameter rp1 = new ReportParameter("ReportParameter1", reportParm1);
            ReportParameter rp2 = new ReportParameter("ReportParameter2", reportParm2);
            ReportParameter rp3 = new ReportParameter("ReportParameter3", reportParm3);

            viewReport.reportViewer1.LocalReport.SetParameters(new ReportParameter[] { rp1, rp2, rp3 });

            ReportDataSource rds = new ReportDataSource("DataSet1", sPPurchaseTollQueryBindingSource);

            viewReport.reportViewer1.LocalReport.DataSources.Add(rds);
            viewReport.reportViewer1.LocalReport.Refresh();

            viewReport.ShowDialog();
        }