Beispiel #1
0
        private void PrintGrid(GridControl grid)
        {
            string tempFile = AppConfig.GetTempDirectory() + Database.GetGlobalKey() + ".xls";

            string customer = GetCustomerNo();
            string strDate  = GetOrderDate();

            ExportInvoice.ExportInvioceTotal(editView, customer, strDate, tempFile);

            if (System.IO.File.Exists(tempFile))
            {
                System.Diagnostics.Process.Start(tempFile);
            }
        }
Beispiel #2
0
        private void ExportPreviewGrid()
        {
            SaveFileDialog fileDialog = new SaveFileDialog();

            fileDialog.Title  = "导出Excel";
            fileDialog.Filter = "Excel (*.xls)|*.xls";
            DialogResult dialogResult = fileDialog.ShowDialog(this);

            if (dialogResult == DialogResult.OK)
            {
                //DevExpress.XtraPrinting.XlsExportOptions options = new DevExpress.XtraPrinting.XlsExportOptions();
                //outboundGrid.ExportToXls(fileDialog.FileName);
                ExportInvoice.ExportInvoiceSelection(outboundView, fileDialog.FileName);

                if (System.IO.File.Exists(fileDialog.FileName))
                {
                    System.Diagnostics.Process.Start(fileDialog.FileName); //保存v
                }
            }
        }
Beispiel #3
0
        private void ExportGrid()
        {
            SaveFileDialog fileDialog = new SaveFileDialog();

            fileDialog.Title  = "导出Excel";
            fileDialog.Filter = "Excel (*.xls)|*.xls";
            DialogResult dialogResult = fileDialog.ShowDialog(this);

            if (dialogResult == DialogResult.OK)
            {
                string customer = GetCustomerNo();
                string strDate  = GetOrderDate();

                ExportInvoice.ExportInvioceTotal(editView, customer, strDate, fileDialog.FileName);

                if (System.IO.File.Exists(fileDialog.FileName))
                {
                    System.Diagnostics.Process.Start(fileDialog.FileName);
                }
            }
        }