var aspose = aspose || {}; aspose.cells = require("aspose.cells"); // Instantiate an instance of the Workbook class and load the source XLSX/XLS file. var workbook = new aspose.cells.Workbook("sample.xlsx"); // Create an object of the MarkdownSaveOptions class to manipulate the xls/xlsx to .md conversion var options = new aspose.cells.MarkdownSaveOptions(); // If the value of setCreateDirectory method is true and the directory does not exist, the directory will be automatically created before saving the file. options.setCreateDirectory(true); // Invoke the setClearData method to make the workbook empty after saving the file. options.setClearData(false); // Call this setLineSeparator method to set the line separator. options.setLineSeparator("#"); // Save as Markdown by invoking the save method workbook.save("Book1.md", options);