瀏覽代碼

winfrom提交

duyong 3 年之前
父節點
當前提交
10993704b1
共有 1 個文件被更改,包括 5 次插入2 次删除
  1. 5 2
      CarMeterSystem/frmMatMsgInfo.cs

+ 5 - 2
CarMeterSystem/frmMatMsgInfo.cs

@@ -53,7 +53,10 @@ namespace CarMeterSystem
 
             UltraGridRow ugr = ultraGrid1.ActiveRow;
 
-            preTrackScaleNo = ugr.Cells["predictionNo"].Value.ToString();
+            if (ugr != null)
+            {
+                preTrackScaleNo = ugr.Cells["predictionNo"].Value.ToString();
+            }
 
             if (weightTypes == "")
             {
@@ -130,7 +133,7 @@ namespace CarMeterSystem
                                          t.FORWARDING_UNIT_NAME forwardingUnitName,
                                          t.TRUST_DATE_TIME trustDateTime
                                          from PRE_TRACK_SCALE t
-                                         where value_flag = '1' and TRUST_AVAILABILITY_TIME >= SYSDATE and CAR_NO = '{0}' and LINE_DESC = '0'", "湘G66666");
+                                         where value_flag = '1' and TRUST_AVAILABILITY_TIME >= SYSDATE and CAR_NO = '{0}' and LINE_DESC = '0'", _carNo);
             DataTable dtV = dtPrediction.Clone();
 
             PbModelDbService<List<PreTrackScale>> pb = new PbModelDbService<List<PreTrackScale>>();