In Excel, we can choose a whole column and apply a number formatting style, it is fast and does not increase the file size since the one formatting has been applied to the whole column.
However, in Aspose, it was not the case, the file size was increated by more than 100x.
var workbook = new Workbook(@".\test.xlsx");
var columnDRange = workbook.Worksheets[“Sheet1”].Cells.CreateRange(1, 3, 1, 1).EntireColumn;
var style = columnDRange[0, 0].GetStyle();
style.Custom = “##0”%"";
var styleFlag = new StyleFlag();
styleFlag.NumberFormat = true;
The file size was 43KB, while after ApplyStyle(), it became 5424KB which made the document not really usable.
If I did the same in Excel, it was only 39KB in the output.
I’ve attached the files for your reference. Could you please help me take a look?
test.zip (1008.0 KB)