Excel を HTML に変換する際の DataBar、ColorScale、および IconSet 条件付き書式をエクスポート
Contents
[
Hide
]
Excel ファイルを HTML に変換する際に DataBar、ColorScale、および IconSet 条件付き書式をエクスポートできます。この機能は Microsoft Excel で部分的にサポートされていますが、Aspose.Cells では完全にサポートされています。
Excel を HTML に変換する際の DataBar、ColorScale、および IconSet 条件付き書式をエクスポート
次のスクリーンショットは DataBar、ColorScale、および IconSet 条件付き書式を含むサンプル Excel ファイル を示しています。提供されたリンクからサンプル Excel ファイルをダウンロードできます。
次のスクリーンショットは Aspose.Cells の出力 HTML ファイルで DataBar、ColorScale、および IconSet 条件付き書式を示しています。サンプル Excel ファイル とまったく同じように見えます。
サンプルコード
次のサンプルコードは、サンプル Excel ファイルを HTML に変換する単なるExcel を HTML に変換する方法です。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// For complete examples and data files, please go to https://github.com/aspose-cells/Aspose.Cells-for-Java | |
// The path to the documents directory. | |
String dataDir = Utils.getDataDir(ConvertingToHTMLFiles.class); | |
// Specify the file path | |
String filePath = dataDir + "Book1.xlsx"; | |
// Specify the HTML saving options | |
HtmlSaveOptions sv = new HtmlSaveOptions(SaveFormat.M_HTML); | |
// Instantiate a workbook and open the template XLSX file | |
Workbook wb = new Workbook(filePath); | |
// Save the HTML file | |
wb.save(dataDir + "output.html", sv); | |
// Print message | |
System.out.println("Excel to HTML conversion performed successfully."); |