private void button1_Click(object sender, EventArgs e)
        {
            this.Cursor = Cursors.WaitCursor;
            int order_ID = Convert.ToInt32(dgvOrders.CurrentRow.Cells[0].Value);

            RPT.rpt_orders      report = new RPT.rpt_orders();
            RPT.FRM_RPT_PRODUCT frm    = new RPT.FRM_RPT_PRODUCT();
            report.SetDataSource(order.GetOrderDetails(order_ID));
            frm.crystalReportViewer1.ReportSource = report;
            frm.ShowDialog();
            this.Cursor = Cursors.Default;
        }
        private void btnPrintOrder_Click(object sender, EventArgs e)
        {
            //Get the last order
            this.Cursor = Cursors.WaitCursor;
            int order_id = Convert.ToInt32(order.GET_LAST_ORDER_FOR_PRINT().Rows[0][0]);

            RPT.rpt_orders        reporto = new RPT.rpt_orders();
            RPT.FRM_RPT_PRODUCTcs frm     = new RPT.FRM_RPT_PRODUCTcs();
            reporto.SetDataSource(order.GET_ORDER_DETAILS(order_id));
            frm.crystalReportViewer1.ReportSource = reporto;
            frm.ShowDialog();
            this.Cursor = Cursors.Default;
        }
Exemplo n.º 3
0
        private void btnPrint_Click(object sender, EventArgs e)
        {
            //get The last order
            this.Cursor = Cursors.WaitCursor;
            int order_ID = Convert.ToInt32(order.GET_LAST_ORDER_FOR_PRINT().Rows[0][0]);

            RPT.rpt_orders      report = new RPT.rpt_orders();
            RPT.FRM_RPT_PRODUCT frm    = new RPT.FRM_RPT_PRODUCT();
            report.SetDataSource(order.GetOrderDetails(order_ID));
            frm.crystalReportViewer1.ReportSource = report;
            frm.ShowDialog();
            this.Cursor = Cursors.Default;
        }
Exemplo n.º 4
0
        private void btnprintinvoice_Click(object sender, EventArgs e)
        {
            //get  the last order



            int order_id = Convert.ToInt32(orders.get_last_order_forprint().Rows[0][0]);

            RPT.rpt_orders  report = new RPT.rpt_orders();
            RPT.FRM_RPT_CAR frm    = new RPT.FRM_RPT_CAR();
            report.SetParameterValue("@order_id", order_id);
            frm.crystalReportViewer1.ReportSource = report;
            frm.ShowDialog();
        }
Exemplo n.º 5
0
        private void btnPrintOrdersList_Click(object sender, EventArgs e)
        {
            //Get the last order
            this.Cursor = Cursors.WaitCursor;
            int order_id = Convert.ToInt32(dvbOrders.CurrentRow.Cells[0].Value);

            RPT.rpt_orders        reporto = new RPT.rpt_orders();
            RPT.FRM_RPT_PRODUCTcs frm     = new RPT.FRM_RPT_PRODUCTcs();
            reporto.Refresh();
            reporto.SetDataSource(order.GET_ORDER_DETAILS(order_id));
            frm.crystalReportViewer1.ReportSource = reporto;
            frm.ShowDialog();
            this.Cursor = Cursors.Default;
        }