将Excel工作簿转换为Ods,Sxc和Fods (OpenOffice / LibreOffice calc)

关于OpenDocument

OpenDocument format (ODF)是一种免费开放的用于电子办公文档的文件格式,最初由Sun开发用于Open Office套件。 OpenDocument Spreadsheet (ODS)是Excel文档的文件格式。 OpenDocument目前是OASIS和ISO标准。

将Ods(OpenOffice / LibreOffice calc)转换为Excel

Aspose.Cells for Python via .NET支持加载Ods、Sxc和Fods,这些都是OpenOffice / LibreOffice Calc支持的文件格式,并将Ods(book1.ods)、Sxc(book1.sxc)和Fods(book1.fods)转换为Excel文件。

from aspose.cells import Workbook
# For complete examples and data files, please go to https:# github.com/aspose-cells/Aspose.Cells-for-.NET
# Load your source ods file
workbook = Workbook("book1.ods")
# Save as xlsx file
workbook.save("ods_out.xlsx")
# Load your source sxc file
workbook = Workbook("book1.sxc")
# Save as xls file
workbook.save("sxc_out.xls")
# Load your source fods file
workbook = Workbook("book1.fods")
# Save as xlsb file
workbook.save("fods_out.xlsb")

将Excel转换为Ods(OpenOffice / LibreOffice Calc)

Aspose.Cells for Python via .NET支持将Excel文件转换为Ods、Sxc和Fods文件。下面的代码示例显示了如何将模板(book1.xlsx)转换为Ods、Sxc和Fods文件。

from aspose.cells import Workbook
# For complete examples and data files, please go to https:# github.com/aspose-cells/Aspose.Cells-for-.NET
# Load your source workbook
workbook = Workbook("book1.xlsx")
# Save as ods file
workbook.save("Out.ods")
# Save as sxc file
workbook.save("Out.sxc")
# Save as fods file
workbook.save("Out.fods")

高级主题