Sfoglia il codice sorgente

Report, page mode, export xlsx

MaiXinRong 8 anni fa
parent
commit
679a4686fa
1 ha cambiato i file con 4 aggiunte e 1 eliminazioni
  1. 4 1
      Forms/ReportsFrm.pas

+ 4 - 1
Forms/ReportsFrm.pas

@@ -1468,7 +1468,10 @@ begin
       iCount := 1;
       repeat
       begin
-        sFileName := Format('%s[%d].xls', [ExtractSimpleFileName(AFileName), iCount]);
+        if IsExcel2010 then
+          sFileName := Format('%s[%d].xlsx', [ExtractSimpleFileName(AFileName), iCount]);
+        else
+          sFileName := Format('%s[%d].xls', [ExtractSimpleFileName(AFileName), iCount]);
         ExportPagesXlsReport(iStartPage, iEndPage, sFileName);
         iStartPage := iStartPage + 20;
         iEndPage := Min(iEndPage + 20, PrintEndPage);