Page 1 of 1
Which rows are printed on a specific page
Posted: Tue Mar 27, 2012 7:22 am
by infrax
I'm using RichViewXML and TRVReportHelper generate and print RV documents.
Now let's say that we have a XML with a big table (printed on multiple pages). I want to know which rows are printed on a specific page.
I tried with TRVReportHelper.GetFirstItemOnPage, but with this I just get the item number of the table -> I want to know specific row.
Any way to do this?
Thanks
Posted: Tue Mar 27, 2012 4:17 pm
by Sergey Tkachenko
The answer is not simple, because a row can be printed on multiple pages (and cells of some row may be printed on next pages, with next rows, because of a vertical cell merging).
Can you explain why do you need it? May be I will be able to find an alternative solution.
Posted: Thu Mar 29, 2012 11:20 am
by infrax
Well the problem is that we want to print a very big RV (xml generated) file into PDF. Usually it is just one very big table. We are talking 10000 PDF pages and more ...
For 'small' dataset it is working OK (up to 100000 rows), but after that it goes out of memory.
So I was thinking to generate and format pages one by one ....
Posted: Thu Mar 29, 2012 1:30 pm
by Sergey Tkachenko
Where does it goes out of memory? While formatting (RVReportHelper.Init + FormatNextPage) or when generating PDF?
Posted: Mon Apr 02, 2012 7:51 am
by infrax
It goes while I'm building XML document (with RichViewXML).
I haven't tried building that big document directly in RV ...
Posted: Mon Apr 02, 2012 9:30 am
by infrax
What would you recommend?
What is the best/right way to generate large reports, using RV?
Generating PDF (the component for this) is not a problem. I tired to create 1GB dummy file and it was OK.
In any case, if we're building report in parts, the problems are page numbers. You don't know the total page count, until you finish.
Thanks
Posted: Mon Apr 02, 2012 5:16 pm
by Sergey Tkachenko
I think generating the report in parts is the only solution.
Do you need to display a page count on each page?
Posted: Tue Apr 03, 2012 6:05 am
by infrax
Usually yes, but maybe in this case we could leave it out.
I think the only solution for this is to go over the whole PDF file again and print header/footer with page count (if the header/footer height is the same). Any other way?
OK in parts then. And back to my first question. Usually in this bit reports we have just one big table. Now you should somehow know when did you stop printing one part to start with the next one. I was thinking, if you know which row was printed on the last-1 page, you could generate & print the next part starting on a new page like it was one print (one iteration).
Thanks
Posted: Tue Apr 03, 2012 6:45 am
by Sergey Tkachenko
If you generate a report in parts, I think the real questions is how to start printing the next part at the same place where the previous part is ended?
If you separate a large document in parts, you already knows which parts consists of which rows.
When you finish printing a part N, you can get its height as HeightN = RVReportHelper.GetLastPageHeight, so you can start printing a part N+1 at YN+HeightN.
Posted: Tue Apr 03, 2012 9:09 am
by infrax
True, but I want to do this with tables.
So the requirements are:
- have the table header row at every page (can be more than 1 row)
- user shouldn't notice when one part ended and the other started (could be a problem if a table/cell has a border)
- have the table footer row only at the last page (this shouldn't be a problem)
Procedure:
- printing 1 part (without footer row)
- at the end of 1 part (page N), I know where it ended (Height1: height as you showed)
- now I must generate a new xml with a table
- it should start the next part (at page N) at Height1, but without header row
- page N+1 starts normally with header row
- ...
Is there an option not to print header rows at the first page?
Thanks
Posted: Thu Apr 05, 2012 5:43 pm
by Sergey Tkachenko
This option will be added in the next update
(rvtoContinue in table.PrintOptions)
Posted: Tue Apr 10, 2012 1:43 pm
by infrax
OK, great.
When can we expect this next update, approximately?
Posted: Tue Apr 10, 2012 7:10 pm
by Sergey Tkachenko
Later in this week
Posted: Fri Apr 13, 2012 8:17 am
by Sergey Tkachenko
Implemented in version 13.10 (uploaded for registered users)
Posted: Wed Apr 18, 2012 11:45 am
by infrax
It's working
.
Thanks