章政 %!s(int64=7) %!d(string=hai) anos
pai
achega
2b1502cfdf
Modificáronse 1 ficheiros con 1 adicións e 6 borrados
  1. 1 6
      UAS-MES/DbFind.cs

+ 1 - 6
UAS-MES/DbFind.cs

@@ -267,13 +267,8 @@ namespace UAS_MES
         //列宽发生变化的时候TextBox的宽度也发生变化
         private void DbFindGridView_ColumnWidthChanged(object sender, DataGridViewColumnEventArgs e)
         {
-            try
-            {
+            if (ctl != null)
                 ctl[DbFindGridView.Columns.IndexOf(e.Column)].Width = e.Column.Width;
-            }
-            catch (Exception)
-            {
-            }
         }
 
         private void DbFindGridView_Scroll(object sender, ScrollEventArgs e)