Export Document Workbook and Worksheet Properties in Excel to HTML conversion

Possible Usage Scenarios

When Microsoft Excel file is exported to HTML using Microsoft Excel or Aspose.Cells, it also exports various types of Document, Workbook and Worksheet properties as shown in the following screenshot. You can avoid exporting these properties by setting the HtmlSaveOptions.ExportDocumentPropertiesHtmlSaveOptions.ExportWorkbookProperties and HtmlSaveOptions.ExportWorksheetProperties as false. The default value of these properties is true. The following screenshot shows how these properties look like in exported HTML.

todo:image_alt_text

Export Document, Workbook and Worksheet Properties in Excel to HTML conversion

The following sample code loads the sample Excel file and converts it to HTML and does not export the Document, Workbook and Worksheet properties in output HTML.

Sample Code

// For complete examples and data files, please go to https://github.com/aspose-cells/Aspose.Cells-for-Java
//Load the sample Excel file
Workbook workbook = new Workbook("sampleExportDocumentWorkbookAndWorksheetPropertiesInHTML.xlsx");
//Specify Html Save Options
HtmlSaveOptions options = new HtmlSaveOptions();
//We do not want to export document, workbook and worksheet properties
options.setExportDocumentProperties(false);
options.setExportWorkbookProperties(false);
options.setExportWorksheetProperties(false);
//Export the Excel file to Html with Html Save Options
workbook.save("outputExportDocumentWorkbookAndWorksheetPropertiesInHTML.html", options);