Page Break issue on .ODS

Hi
Doing a page break delimitation foreach cell based on the value. In this case we’ve lookup for “Order_type” value.
It’s dooing ok the page breaks on .PDF, but no effect on spreadsheets format (.ODS).
Code (and the feed file attached):
string csvRepData = $"{pathToTemp}rep-data.csv";
newReport = $"{pathToTemp}DetailFormat.ods";

            TxtLoadOptions loadOptions = new TxtLoadOptions(LoadFormat.Csv);
            loadOptions.Encoding = Encoding.UTF7;

            #region Set Data
            Workbook book = new Workbook(csvRepData, loadOptions);
            Worksheet worksheet = book.Worksheets[0];
            Cells cells = worksheet.Cells;

            cells.DeleteRow(0);
            cells.DeleteColumn(2, true);
            
            title = "ALL ITEM DETAILS HELD FOR ORDER: "
            PageSetup pageSetup = book.Worksheets[0].PageSetup;
            pageSetup.SetHeader(0, "&\"Times New Roman,Bold\"ParkMap");
            pageSetup.SetHeader(1, $"&\"Times New Roman,Bold\"{title}");
            pageSetup.SetHeader(2, "&\"Times New Roman,Bold\"&D");

           List<Cell> lstCellsPageB = new List<Cell>();
            FindOptions opts = new FindOptions();
            opts.LookInType = LookInType.Values;
            opts.LookAtType = LookAtType.EntireContent;

            foreach (Cell cell in cells)
            {
                if (cell.Value.ToString().Equals("Order_Type", StringComparison.OrdinalIgnoreCase))
                {
                    lstCellsPageB.Add(cell);
                }              
            }

foreach (var item in lstCellsPageB)
            {
                worksheet.HorizontalPageBreaks.Add(item.Name);
                worksheet.VerticalPageBreaks.Add(item.Name);
            }

newReport = pathToTemp + "ScheduleList.pdf";
book.Save(newReport, SaveFormat.Pdf);
//newReport = pathToTemp + "ScheduleList.ods";
//book.Save(newReport, SaveFormat.Ods);

rep-data.zip (1.9 KB)

@Remus87
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): CELLSNET-53091

@Remus87
It must be the bug of MS Excel.

  1. Please open generated ODS file with OpenOffice or LibreOffice, you can see those Page breaks work fine.

  2. If you load generated ODS file and save it as XLSX with Aspose.Cells as the following:
    Workbook book = new Workbook(dir + “1.ods”);
    book.Save(dir + “dest.xlsx”);
    you will find those page breaks when opening the XLSX with MS Excel.

  3. If you manually insert page breaks in OpenOffice or LibreOffice to ODS file, MS Excel ignores those Page breaks too.