Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.
The following sample code uses the WorkbookMetadata class to edit custom document properties of a workbook. Once you open the workbook using the Workbook class, you will be able to read the document properties. Here is sample code using the WorkbookMetadata class.
const path = require("path");
const AsposeCells = require("aspose.cells.node");
// The path to the documents directory.
const dataDir = path.join(__dirname, "data");
// Open workbook metadata
const options = new AsposeCells.MetadataOptions(AsposeCells.MetadataType.Document_Properties);
const meta = new AsposeCells.WorkbookMetadata(path.join(dataDir, "Sample1.xlsx"), options);
// Set some properties
meta.getCustomDocumentProperties().add("test", "test");
// Save the metadata information
meta.save(path.join(dataDir, "Sample2.out.xlsx"));
// Open the workbook
const w = new AsposeCells.Workbook(path.join(dataDir, "Sample2.out.xlsx"));
// Read document property
console.log(w.getCustomDocumentProperties().get("test"));
console.log("Press any key to continue...");
Analyzing your prompt, please hold on...
An error occurred while retrieving the results. Please refresh the page and try again.