|
|
@@ -2511,6 +2511,7 @@ namespace UAS_LabelMachine
|
|
|
if (result == DialogResult.OK)
|
|
|
{
|
|
|
ExcelHandler eh = new ExcelHandler();
|
|
|
+
|
|
|
DataTable dt = ((DataTable)MidSource.DataSource).Copy();
|
|
|
for (int i = 0; i < dt.Columns.Count; i++)
|
|
|
{
|
|
|
@@ -2523,7 +2524,9 @@ namespace UAS_LabelMachine
|
|
|
}
|
|
|
}
|
|
|
eh.ExportExcel(dt, ExportFileDialog.SelectedPath, pi_inoutno.Text);
|
|
|
- MessageBox.Show("导出成功");
|
|
|
+ string close = MessageBox.Show(this.ParentForm, "导出成功,是否打开文件", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question).ToString();
|
|
|
+ if (close.ToString() == "Yes")
|
|
|
+ System.Diagnostics.Process.Start(ExportFileDialog.SelectedPath + "\\" + pi_inoutno.Text + ".xls");
|
|
|
}
|
|
|
}
|
|
|
}
|