diff --git a/funcext/TSOffice/TOfficeObj.tsf b/funcext/TSOffice/TOfficeObj.tsf index 87c4dae..751d177 100644 --- a/funcext/TSOffice/TOfficeObj.tsf +++ b/funcext/TSOffice/TOfficeObj.tsf @@ -1,4 +1,4 @@ -// Version 1.6.0 +// Version 1.6.1 Function TOfficeObj(n); Begin case lowercase(n) of diff --git a/funcext/TSOffice/TSDocxFile.tsf b/funcext/TSOffice/TSDocxFile.tsf index 60a4142..e7cc159 100644 --- a/funcext/TSOffice/TSDocxFile.tsf +++ b/funcext/TSOffice/TSDocxFile.tsf @@ -1,4 +1,4 @@ -// Version 1.6.0 +// Version 1.6.1 Type TSDocxFile = Class ///Version: V1.0 2022-09-20 ///适用于 Microsoft Word docx格式文件 diff --git a/funcext/TSOffice/TSXlsxFile.tsf b/funcext/TSOffice/TSXlsxFile.tsf index c3636aa..6ef1b70 100644 --- a/funcext/TSOffice/TSXlsxFile.tsf +++ b/funcext/TSOffice/TSXlsxFile.tsf @@ -1,4 +1,4 @@ -// Version 1.6.0 +// Version 1.6.1 Type TSXlsxFile = Class ///Version: V1.0 2022-08-08 ///适用于 Microsoft Excel? 2007 及以上版本创建的电子表格文档。支持 XLSX / XLSM / XLTM / XLTX 等多种文档格式。 diff --git a/funcext/TSOffice/worksheet/xlsxStyles.tsf b/funcext/TSOffice/worksheet/xlsxStyles.tsf index 7f8f16c..6112101 100644 --- a/funcext/TSOffice/worksheet/xlsxStyles.tsf +++ b/funcext/TSOffice/worksheet/xlsxStyles.tsf @@ -155,12 +155,12 @@ Type xlsxStyles = Class if numfmt_id >= 1 and numfmt_id <= 10 then return array('n', value); if numfmt_id >= 11 and numfmt_id <= 26 then begin - if ifstring(value) and (trystrtodate(value, r) or trystrtodatetime(value, r)) then return array('n', r); + if ifstring(value) and (trystrtodate(value, r) or trystrtodatetime(value, r) or trystrtotime(value, r)) then return array('n', r); t := ifstring(value) ? 's' : 'n'; return array(t, value); end if numfmt_id >= 27 and numfmt_id <= 34 then return array('e', value); - if numfmt_id >= 35 and numfmt_id <= 48 then return array('n', trystrtofloat(value, r) ? r : value); + if numfmt_id >= 35 and numfmt_id <= 48 then return array('n', value); if numfmt_id = 49 then return array('s', value); if numfmt_id >= 50 and numfmt_id <= 55 then begin @@ -375,6 +375,7 @@ End; // numfmtid为32表示错误值格式,即显示为#NUM!。 // numfmtid为33表示错误值格式,即显示为#N/A。 // numfmtid为34表示错误值格式,即显示为#GETTING_DATA。 +// numfmtid是35表示货币格式,即显示为带有货币符号的数值,且小数位数为0。 // numfmtid为36表示货币格式,即显示为带有货币符号和负数红色的数值。 // numfmtid为38表示会计格式,即显示为带有货币符号和负数红色的数值,且小数位数为2。 // numfmtid为39表示会计格式,即显示为带有货币符号和负数红色的数值,且小数位数为0。 diff --git a/更新日志.md b/更新日志.md index 77dd181..6a70301 100644 --- a/更新日志.md +++ b/更新日志.md @@ -2,11 +2,19 @@ ## 2023-2-5 +### V1.6.1 + +#### excel + +1. 修复excel文件单元格原有类型与tsl类型转换报错问题(trystrtofloat) + +## 2023-2-5 + ### V1.6.0 #### excel -1. 兼容Excel2016,通过`NewSheet/InsertSheet`创建工作表不再提示修复错误 +1. 兼容 Excel2016,通过`NewSheet/InsertSheet`创建工作表不再提示修复错误 2. 修复带有表头的二维数组通过`InsertTable`写入数据只写入表头未写入数据问题 ## 2023-1-31