예제 #1
0
        private void Barcode(object sender, EventArgs e)
        {
            if (((MainForm)this.MdiParent).ActiveMdiChild == this)
            {
                List <int> CheckList = new List <int>();

                foreach (DataGridViewRow row in dgvCompanyList.Rows)
                {
                    DataGridViewCheckBoxCell chk = (DataGridViewCheckBoxCell)dgvCompanyList[0, row.Index];

                    if (chk.Value == null)
                    {
                        continue;
                    }
                    else if ((bool)chk.Value == true)
                    {
                        CheckList.Add(dgvCompanyList[1, row.Index].Value.ToInt());
                    }
                }

                if (CheckList.Count == 0)
                {
                    MessageBox.Show("거래처를 선택하여 주세요.");
                    return;
                }

                string         selList = string.Join(",", CheckList);
                CompanyService service = new CompanyService();
                DataTable      dt      = service.CompanyPrint(selList);

                CompanyReport xtra = new CompanyReport();
                xtra.DataSource = dt;
                ReportPreviewForm frm = new ReportPreviewForm(xtra);
            }
        }
        private void Barcode(object sender, EventArgs e)
        {
            if (((MainForm)this.MdiParent).ActiveMdiChild == this)
            {
                BarCodeProductBOM report = new BarCodeProductBOM();

                report.DataSource = pdSv.SelectAllProductsToTable();
                report.CreateDocument();

                ReportPreviewForm frm = new ReportPreviewForm(report);
            }
        }
예제 #3
0
        private void Barcode(object sender, EventArgs e)
        {
            if (((MainForm)this.MdiParent).ActiveMdiChild == this)
            {
                string employee_id = dataGridViewControl1.GetCheckIDs("EMPLOYEE_ID");

                if (string.IsNullOrEmpty(employee_id))
                {
                    return;
                }

                DataTable       barcodeDt       = employeeService.GetEmployees(employee_id);
                BarcodeEmployee barcodeEmployee = new BarcodeEmployee();
                barcodeEmployee.DataSource = barcodeDt;

                ReportPreviewForm frm = new ReportPreviewForm(barcodeEmployee);
            }
        }