Browse Source

批量插入子、后项,部位,复制粘贴后,多增一空列。

MaiXinRong 9 years atrás
parent
commit
bb383117ab
1 changed files with 2 additions and 2 deletions
  1. 2 2
      Forms/BatchInsertBillsFrm.pas

+ 2 - 2
Forms/BatchInsertBillsFrm.pas

@@ -199,8 +199,8 @@ end;
 procedure TBatchInsertBillsForm.SetRowAndColumnCount(AGrid: TZJGrid;
   ASourSheet: TZjSheet);
 begin
-  if AGrid.ColCount < ASourSheet.ColCount + AGrid.CurCol then
-    AGrid.ColCount := ASourSheet.ColCount + AGrid.CurCol;
+  if AGrid.ColCount < ASourSheet.ColCount + AGrid.CurCol + 1 then
+    AGrid.ColCount := ASourSheet.ColCount + AGrid.CurCol + 1;
   if AGrid.RowCount < ASourSheet.RowCount + AGrid.CurRow + 1 then
     AGrid.RowCount := ASourSheet.RowCount + AGrid.CurRow + 1;
 end;