v1.5.9
This commit is contained in:
parent
522e52ed46
commit
6d6281229c
|
|
@ -1,4 +1,4 @@
|
|||
// Version 1.5.8
|
||||
// Version 1.5.9
|
||||
Function TOfficeObj(n);
|
||||
Begin
|
||||
case lowercase(n) of
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
// Version 1.5.8
|
||||
// Version 1.5.9
|
||||
Type TSDocxFile = Class
|
||||
///Version: V1.0 2022-09-20
|
||||
///适用于 Microsoft Word docx格式文件
|
||||
|
|
@ -49,7 +49,7 @@ Type TSDocxFile = Class
|
|||
Begin
|
||||
if not ifObj(zipfile_) then return array(-1, 'Create ZipFile object fail.');
|
||||
if zipfile_.FilesCount() > 0 then zipfile_ := new ZipFile();
|
||||
[err, errmsg] := zipfile_.Open(alias, fname, passwd);
|
||||
[err, errmsg] := zipfile_.Open(alias, TOfficeApi().CurCodePageToGBK(fname), passwd);
|
||||
if err=0 then Begin
|
||||
document_ := new docxDocument(zipfile_);
|
||||
End;
|
||||
|
|
@ -87,7 +87,7 @@ Type TSDocxFile = Class
|
|||
///返回: [err, info]
|
||||
Function SaveAs(alias, fname);
|
||||
Begin
|
||||
return zipfile_.Save(alias, fname);
|
||||
return zipfile_.Save(alias, TOfficeApi().CurCodePageToGBK(fname));
|
||||
End;
|
||||
|
||||
///另存为二进制流数据
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
// Version 1.5.8
|
||||
// Version 1.5.9
|
||||
Type TSXlsxFile = Class
|
||||
///Version: V1.0 2022-08-08
|
||||
///适用于 Microsoft Excel? 2007 及以上版本创建的电子表格文档。支持 XLSX / XLSM / XLTM / XLTX 等多种文档格式。
|
||||
|
|
@ -45,7 +45,7 @@ Type TSXlsxFile = Class
|
|||
Begin
|
||||
if not ifObj(zipfile_) then return array(-1, 'Create ZipFile object fail.');
|
||||
if zipfile_.FilesCount() > 0 then zipfile_ := new ZipFile();
|
||||
[err, errmsg] := zipfile_.Open(alias, fname, passwd);
|
||||
[err, errmsg] := zipfile_.Open(alias, TOfficeApi().CurCodePageToGBK(fname), passwd);
|
||||
if err=0 then InitVars();
|
||||
return array(err, errmsg);
|
||||
End;
|
||||
|
|
@ -96,7 +96,7 @@ Type TSXlsxFile = Class
|
|||
///返回: [err, info]
|
||||
Function SaveAs(alias, fname);
|
||||
Begin
|
||||
return zipfile_.Save(alias, fname);
|
||||
return zipfile_.Save(alias, TOfficeApi().CurCodePageToGBK(fname));
|
||||
End;
|
||||
|
||||
///真实文件名
|
||||
|
|
|
|||
Loading…
Reference in New Issue