|
|
@@ -113,7 +113,15 @@ namespace UAS_LabelMachine
|
|
|
LabelCode = LabelDataGridView.Rows[e.RowIndex].Cells["cl_labelcode"].Value.ToString();
|
|
|
CL_ID1 = LabelDataGridView.Rows[e.RowIndex].Cells["cl_id"].Value.ToString();
|
|
|
La_id1 = LabelDataGridView.Rows[e.RowIndex].Cells["la_id"].Value.ToString();
|
|
|
- System.DateTime time = Convert.ToDateTime(LabelDataGridView.Rows[e.RowIndex].Cells["cl_date"].Value.ToString());
|
|
|
+ System.DateTime time;
|
|
|
+ try
|
|
|
+ {
|
|
|
+ time = Convert.ToDateTime(LabelDataGridView.Rows[e.RowIndex].Cells["cl_date"].Value.ToString());
|
|
|
+ }
|
|
|
+ catch (Exception)
|
|
|
+ {
|
|
|
+ time = System.DateTime.Now;
|
|
|
+ }
|
|
|
if (CodeSoft.Checked)
|
|
|
{
|
|
|
string LabelName = LabelDataGridView.Rows[e.RowIndex].Cells["cl_labelname"].Value.ToString();
|
|
|
@@ -134,7 +142,15 @@ namespace UAS_LabelMachine
|
|
|
CL_ID2 = LabelDataGridView.Rows[e.RowIndex].Cells["cl_id"].Value.ToString();
|
|
|
LabelPath = LabelDataGridView.Rows[e.RowIndex].Cells["cl_labelurl"].Value.ToString();
|
|
|
string LabelName = LabelDataGridView.Rows[e.RowIndex].Cells["cl_labelname"].Value.ToString();
|
|
|
- System.DateTime time = Convert.ToDateTime(LabelDataGridView.Rows[e.RowIndex].Cells["cl_date"].Value.ToString());
|
|
|
+ System.DateTime time;
|
|
|
+ try
|
|
|
+ {
|
|
|
+ time = Convert.ToDateTime(LabelDataGridView.Rows[e.RowIndex].Cells["cl_date"].Value.ToString());
|
|
|
+ }
|
|
|
+ catch (Exception)
|
|
|
+ {
|
|
|
+ time = System.DateTime.Now;
|
|
|
+ }
|
|
|
BaseUtil.GetLabelUrl(LabelPath, LabelName, time);
|
|
|
System.Diagnostics.Process.Start(ftpOperater.DownLoadTo + LabelName);
|
|
|
客户编号.Text = LabelDataGridView.Rows[e.RowIndex].Cells["CL_CUSTCODE2"].Value.ToString();
|