禁用导出框架脚本与文档属性,使用 C++ 通过 Node.js

禁用导出框架脚本和文档属性

以下示例代码允许您禁用导出框架脚本和文档属性。一旦您将工作簿转换为HTML,输出文件将不包含任何框架脚本和文档属性。

const path = require("path");
const AsposeCells = require("aspose.cells.node");

// The path to the documents directory.
const dataDir = path.join(__dirname, "data");

// Open the required workbook to convert
const filePath = path.join(dataDir, "Sample1.xlsx");
const workbook = new AsposeCells.Workbook(filePath);

// Disable exporting frame scripts and document properties
const options = new AsposeCells.HtmlSaveOptions();
options.setExportFrameScriptsAndProperties(false);

// Save workbook as HTML
workbook.save(path.join(dataDir, "output.out.html"), options);