Free Support Forum - aspose.com

Problem with Print Titles with aspose cells (Rows to repeat at top issue)

Hi,

I’m using aspose cells with XLS templates to generate both Excel and PDF reports.

In PDF report I need one row (Row contain titles of columns of table below it) to be repeated on each page except first one.

I tried to do it in excel and it work and “Print Titles” -> “Rows to repeat” work fine.
But using aspose cells the row repeated on every page including first one.

All examples that I found were like pageSetup.Repeatrows = “$1:$9” and it works fine, but in my case I need pageSetup.Repeatrows = “$9:$9” and in this case i go the described problem.

Looking forward to any advice.

Thank you,
Dmitry.

Hi,

Thank you for considering Aspose.

I tested your issue with the attached latest version and found no problem. Please check the input and output files. Following is the sample code:

Workbook workbook = new Workbook();

workbook.Open("C:\\book1.xls");

//Obtaining the reference of the PageSetup of the worksheet

Aspose.Cells.PageSetup pageSetup = workbook.Worksheets[0].PageSetup;

//Defining row number9 as title row

pageSetup.PrintTitleRows = "$9:$9";

workbook.Save("C:\\TestingCells.pdf", FileFormatType.Pdf);

If you still face any problem with the attached latest version, please share your template & generated file with sample code and we will check it soon.

Thank You & Best Regards,

Hi,

Thank you for your response. But the problem persists and in your example. First 8 rows should contain it’s original data and first page shouldn’t has first row as header.

Please take a look to the attached example. Please take a look to “print preview” in excel for XLS file.

Thank you,
Dmitry.

Hi,

Thank you for considering Aspose.

We have found your mentioned issue after an initial test. We will look into it and get back to you soon. Your issue has been registered in our issue tracking system with issue id CELLSNET-12549.

Thank You & Best Regards,

Hi,

Please try the attached version, we have fixed your mentioned issue.

Thank you.

Hey,


It works fine now.

Thank you,
Dmitry.


Hi guys,


We faced new issue with the Aspose.Cells v 4.8.1.8.

There is a error while saving content as PDF file:

Aspose.Cells.CellsException: Invalid column index. at
x9d2539cac3622db3.x809c66442c41384d.xbe3b30e9ba403eed(Int32
xe3e287548b3d01f5)
at Aspose.Cells.Cells.GetColumnWidth(Int32
column)
at xf1e06fd8be9d8c69.xd285aa8659b8b74e.x5750c24895eed653(Boolean
x1535843ec4bba19c, Int32 x6155c61fc47ceb1a, Int32 xa364300db00bde74, Int32
x433508a87b1e0cdf, Int32 x8e5bc30d03570f25)
at
xf1e06fd8be9d8c69.xd285aa8659b8b74e.xca7ee98176b7e9a9(CellArea
xb1059955b0ff5e89, Boolean xf14244aa8a7f4a9d)
at
xf1e06fd8be9d8c69.xd285aa8659b8b74e.x4ada424795451863(CellArea
xb1059955b0ff5e89, Boolean xf14244aa8a7f4a9d, XmlNode xc301afa072787492)

at xf1e06fd8be9d8c69.xd285aa8659b8b74e.xeca24e4cdf174f7b(XmlNode
xc301afa072787492, Int32 x69e9b567129e96cb)
at
xf1e06fd8be9d8c69.xd285aa8659b8b74e.x6210059f049f0d48()
at
xf1e06fd8be9d8c69.xd285aa8659b8b74e.x0acd3c2012ea2ee8(Stream xcf18e5243f8d8d5fd3)
at
xf1e06fd8be9d8c69.xd285aa8659b8b74e.x0acd3c2012ea2ee8(Stream xcf18e5243f8d8d5fd3)
at
Aspose.Cells.Workbook.Save(Stream stream, FileFormatType fileFormatType)


This does not happen on 4.8.0.0 version!

I’m attaching excel file that causes the issue.
To reproduce the issue you can try the following code:


Workbook wb = new Workbook();
wb.LoadData(“report.xls”);
wb.Save(“report.pdf”, FileFormatType.Pdf);

please let me know if there’s something that we can do urgently, since we have a release next week and this blocks the whole thing now. The highest risk so far.

-Sergey

Hi,<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thank you for considering Aspose.

We will look into you issue and get back to you soon.

Also, I have attached the latest version of Aspose.Cells, so you may try it and check if it works fine for you. Also, you may try Workbook.Open method instead of Workbook.LoadData to see if it works fine for you.

Thank You & Best Regards,

Wow,

thank you for such a quick reply!

So far 4.8.1.10 works well on sandbox project. I will test it in real system and reply with results.

Thank you!

-Sergey

I’m also wondering why it takes so much memory to make PDF conversion?

I currently have out of memory exception while converting excel file.
For example that 11 Mb file (attached in prev. post) ates > 1Gb memory and kills 100% cpu for 5 minutes.
is this an expected behavior or there is something wrong with file formatting?

Hi,

Well, since your excel workbook has a big worksheet (65k rows * certain columns) with second worksheet also has 17k records, so this process needs a lot of memory to complete the task. Anyways, we have found the issue after an initial test and will look into it soon. Your issue has been logged into our issue tracking system with an issue id: CELLSNET-12927.

We will get back to you soon.

Thank you.

I just run a test with 4.8.0.0 and it was running under 280Mb of RAM and is always successful without errors. So this might be something in new code. Hope to see a new build soon with both headers and good memory management :wink:


thank you!

The issues you have found earlier (filed as 12549) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.