Hi,
Hi,
Thanks for your posting and using Aspose.Cells.
As a workaround, you should first combine all the worksheets into a single worksheet and then save your workbook in html format.
Please see the following documentation article that illustrates how to combine multiple worksheets into a single worksheet.
Please also see the following sample code. I have attached the output Excel file and the output HTML for your reference.
C#
string[] files = {“Excel1.xlsx”, “Excel2.xlsx” };
Workbook destWorkbook = new Workbook();
Worksheet destSheet = destWorkbook.Worksheets[0];
int TotalRowCount = 0;
for (int i = 0; i < files.Length; i++)
{
Workbook workbook = new Workbook(files[i]);
Worksheet sourceSheet = workbook.Worksheets[0];
Range sourceRange = sourceSheet.Cells.MaxDisplayRange;
Range destRange = destSheet.Cells.CreateRange(sourceRange.FirstRow + TotalRowCount, sourceRange.FirstColumn,
sourceRange.RowCount, sourceRange.ColumnCount);
destRange.Copy(sourceRange);
TotalRowCount = sourceRange.RowCount + TotalRowCount;
}
destWorkbook.Save(“output.xlsx”);
HtmlSaveOptions opts = new HtmlSaveOptions();
destWorkbook.Save(@“F:\Shak-Data-RW\Downloads\output.html”, opts);
Hi,
Thanks for your posting and using Aspose.Cells.
We have logged a New Feature (Improvement) in our database to support this feature. We will look into it and see if it can be implemented. If we need some more information from your part, we will ask. Once, this feature is implemented or we have some other update for you, we will let you know asap.
This issue has been logged as
- CELLSNET-43368 - Customizing the generation of CSS while saving Excel to HTML
Hi,
Thanks for your using Aspose.Cells.
Please download and try the latest fix: Aspose.Cells for .NET v8.3.2.7 and let us know your feedback.
There are some tips for you:
1. Adds HtmlSaveOptions.CellCssPrefix attribute. Indicates the cell style prefix, the default value is “”.
The sample codes as follows:
C#
Workbook wb = new Workbook(“a.xlsx”);
HtmlSaveOptions options = new HtmlSaveOptions();
options.CellCssPrefix= “e1”;
wb.Save(“out.html”, options);
The issues you have found earlier (filed as CELLSNET-43368) have been fixed in this update.
This message was posted using Notification2Forum from Downloads module by Aspose Notifier.