예제 #1
0
        private void btPrint_Click(object sender, EventArgs e)
        {
            if (this.invoiceMasterBindingSource.Count == 0)
            {
                return;
            }

            MDataSet.InvoiceMasterRow _curentMasterRow = (this.invoiceMasterBindingSource.Current as DataRowView).Row as MDataSet.InvoiceMasterRow;

            if (_curentMasterRow == null)
            {
                return;
            }

            try
            {
                FormPrintDialog fromDialog       = new FormPrintDialog("/ReportRetailTrade/InvoiceMasterByID");
                ReportParameter ReceiptMasterRef = new ReportParameter("InvoiceMasterRef", _curentMasterRow.ID.ToString());

                fromDialog.reportViewer.ServerReport.SetParameters(new ReportParameter[] { ReceiptMasterRef });
                fromDialog.ShowDialog(this);
            }
            catch (Exception err)
            {
                MessageBox.Show(err.Message);
            }
        }
예제 #2
0
        //Report
        public void ProductReport(int ProductRef)
        {
            FormPrintDialog fromDialog = new FormPrintDialog("/ReportRetailTrade/ProductReport");


            ReportParameter _ProductRef = new ReportParameter("ProductRef", ProductRef.ToString());

            fromDialog.reportViewer.ShowParameterPrompts = true;
            fromDialog.reportViewer.ServerReport.SetParameters(new ReportParameter[] { _ProductRef });
            fromDialog.ShowDialog(this);
        }
예제 #3
0
파일: MainForm.cs 프로젝트: vpjulia/Salvia
 public void ProductReport(int productRef)
 {
     try
     {
         FormPrintDialog formPrintDialog = new FormPrintDialog("RetailTradeOrders.Resources.ProductReport.rdlc");
         formPrintDialog.ProductRef = productRef;
         formPrintDialog.ShowDialog(this);
     }
     catch (Exception err)
     {
         MessageBox.Show(err.Message);
     }
 }
예제 #4
0
파일: OrdersAll.cs 프로젝트: vpjulia/Salvia
        private void btOrdersOld_Click(object sender, EventArgs e)
        {
            try
            {
                FormPrintDialog formPrintDialog = new FormPrintDialog("OrdersOld");
                formPrintDialog.TradePutletRef = (this.ParentForm as MainForm).LocalSettingRow.MainTradePutletRef;

                formPrintDialog.ShowDialog(this);
            }
            catch (Exception err)
            {
                MessageBox.Show(err.Message);
            }
        }
예제 #5
0
        private void btPrint_Click(object sender, EventArgs e)
        {
            MDataSet.ReceiptMasterRow row = (this.receiptMasterBindingSource.Current as DataRowView).Row as MDataSet.ReceiptMasterRow;


            FormPrintDialog fromDialog = new FormPrintDialog("/ReportRetailTrade/ReceiptMasterByID");

            ReportParameter ReceiptMasterRef = new ReportParameter("ReceiptMasterRef", row.ID.ToString());

            fromDialog.reportViewer.ServerReport.SetParameters(new ReportParameter[] { ReceiptMasterRef });


            fromDialog.ShowDialog(this);
        }
예제 #6
0
        private void btPrint_Click(object sender, EventArgs e)
        {
            FormPrintDialog fromDialog = new FormPrintDialog("/ReportRetailTrade/InvoiceMasterByID");



            ReportParameter ReceiptMasterRef = new ReportParameter("InvoiceMasterRef", this._curentMasterRow.ID.ToString());

            fromDialog.reportViewer.ServerReport.SetParameters(new ReportParameter[] { ReceiptMasterRef });



            fromDialog.ShowDialog(this);
        }
예제 #7
0
파일: MainForm.cs 프로젝트: vpjulia/Salvia
        private void btReport_Click(object sender, EventArgs e)
        {
            try
            {
                FormPrintDialog formPrintDialog = new FormPrintDialog("RetailTradeCLReriodical");
                formPrintDialog.TradePutletRef = this.LocalSettingRow.MainTradePutletRef;

                formPrintDialog.ShowDialog(this);
            }
            catch (Exception err)
            {
                MessageBox.Show(err.Message);
            }
        }
예제 #8
0
        private void ReportPrint_Click(object sender, EventArgs e)
        {
            if ((sender as ToolStripMenuItem).Tag.ToString().Length == 0)
            {
                return;
            }

            string namereport = (sender as ToolStripMenuItem).Tag.ToString();

            FormPrintDialog fromDialog = new FormPrintDialog("/ReportRetailTrade/" + namereport);



            fromDialog.ShowDialog(this);
        }
예제 #9
0
        private void btStockRep_Click(object sender, EventArgs e)
        {
            try
            {
                FormPrintDialog fromDialog = new FormPrintDialog("/ReportRetailTrade/InvoiceMasterByIdForStock");

                ReportParameter ReceiptMasterRef = new ReportParameter("InvoiceMasterRef", this._curentMasterRow.ID.ToString());

                fromDialog.reportViewer.ServerReport.SetParameters(new ReportParameter[] { ReceiptMasterRef });
                fromDialog.ShowDialog(this);
            }
            catch (Exception err)
            {
                MessageBox.Show(err.Message);
            }
        }
예제 #10
0
파일: OrdersAll.cs 프로젝트: vpjulia/Salvia
        private void btNewReport_Click(object sender, EventArgs e)
        {
            if ((this.ordersBindingSource.Current as DataRowView) != null)
            {
                int _tradePutletRef = ((this.ordersBindingSource.Current as DataRowView).Row as MDataSet.OrdersRow).TradePupletRef;

                FormPrintDialog fromDialog = new FormPrintDialog("/ReportRetailTrade/OrdersNew");


                ReportParameter TradePutletRef = new ReportParameter("TradePutletRef", _tradePutletRef.ToString());


                fromDialog.reportViewer.ServerReport.SetParameters(new ReportParameter[] { TradePutletRef });

                fromDialog.ShowDialog(this);
            }
        }
예제 #11
0
파일: OrdersAll.cs 프로젝트: vpjulia/Salvia
        private void btReport_Click(object sender, EventArgs e)
        {
            if (this.mDataSet.HasChanges())
            {
                MessageBox.Show("Есть несохраненные данные!");
                return;
            }


            if (this.mDataSet.Orders.HasErrors)
            {
                return;
            }


            FormPrintDialog formDialog = new FormPrintDialog("/ReportRetailTrade/OrdersForReport");


            DateTime time = DateTime.Now;


            formDialog.ShowDialog(this);

            //   if (formDialog.ShowDialog(this) == DialogResult.OK)


            if (MessageBox.Show("Закрыть заказанные позиции?", "Закрытие заказа", MessageBoxButtons.OKCancel, MessageBoxIcon.Asterisk) == DialogResult.OK)
            {
                try
                {/*закрыть заявки*/
                    this.ordersTableAdapter.OrdersSetReservedCommand(time);
                    this.ordersTableAdapter.Fill(this.mDataSet.Orders);
                }
                catch (Exception err)
                {
                    MessageBox.Show(err.Message);
                }
            }
        }