JIT Pipeline not moving Records
I am trying to use a JIT pipeline to provide the data from a grid that has
been preloaded with information. However, the data never gets displayed for
all the records. The appropriate number of detail bands are printed (as
evidenced by some lines that are also printed) but the RecordIndex property
never changes. And yes, I have set the RecordCount.
I have seen several posts about this and read them all.. I looked it up on
Tamaracka and still no avail. I have copied directly from the samples but I
am still stuck with this.
Thanks in Advance,
Trevor
been preloaded with information. However, the data never gets displayed for
all the records. The appropriate number of detail bands are printed (as
evidenced by some lines that are also printed) but the RecordIndex property
never changes. And yes, I have set the RecordCount.
I have seen several posts about this and read them all.. I looked it up on
Tamaracka and still no avail. I have copied directly from the samples but I
am still stuck with this.
Thanks in Advance,
Trevor
This discussion has been closed.
Comments
1. Check that the Report.DataPipeline property is assigned to the
JITPipeline. When the Report generates it will traverse the datapipeline to
which it is assigned using method calls such as First, Next, etc. Internally
the JITPipeline will increment its RecordIndex property.
2. There is a JITPipeline tutorial in the Developers Guide
3. There are some JITPipeline examples installed with the demos. Run
RBuilder\Demos\Reports\Demo.dpr and check out the 'no database' section.
There are examples there - including an example of printing from a grid.
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
the JITPipeline doesnt move positions.
Perhaps there is a way around this. The report prints the data from a grid
can only fit in about 8 or 9 "columns" of information in landscape.
However, the grid can often contain 10+ columns. What I am trying to get it
to do is to print the information from the first 9 columns and then (in the
OnCheckEOF is where i thought) go back to the beginning of the report and
have it run through all the records for the remaining columns. My
OnGetFieldValue takes care of returning the proper information for the
"column" that it is on. Basically I need it to run through the data 2 or 3
times (but not a fixed number of times because the number of columns in the
grid is not fixed either)
Thanks in Advance,
Trevor
1. What you are describing is a spreadsheet style report. The following
example shows how to generate a spreadsheet style subreport using
ReportBuilder. (It is not JITPipeline based, but the type of pipeline is
irrelevant. The Report.DataPipeline proeprty is of type TppDataPipeline -
the report engine never knows the specific descendant class type being
used)
www.digital-metaphors.com/tips/SpreadSheetStyleReport.zip
2. A report will traverse the datapipeline from first to last. Once it
encounters EOF, then it will consider that to the end of the data. No
further traversals will take place. Thus implementing OnCheckEOF will not
help.
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
Trevor
Oops. Ok try it again...
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com
works best with a known number of columns. The problem that I had was that
the number of columns could vary from 2 to 50 and even more. I suppose
there is a way I could just add subreports and copy the contents from a
master subreport to duplicate the first part as many times as I need.
Instead I just multiplied the number of records by the calculated number of
times that I was going to have to loop through the data and then
extrapolated which column and record number i was really on. It seems to
work fine like that.
Only thing left is to mention that when you set an OnCheckEOF event handler
on the JITPipeline the record number on the pipeline never moves.
Thanks again.
Trevor
In my testing here the CheckEOF event works correctly. As a simple example,
open the RBuilder\Demos\Reports.dpr project and modify demo 137 (dm137.pas)
as follows:
function Tfrm0137.ppJITPipeline1CheckEOF: Boolean;
begin
Result := ppJitPipeline1.RecordIndex >= ppJitPipeline1.RecordCount-1;
end;
You can also check out the source code to the JITPipeline (ppDBJIT.pas).
Best regards,
Nard Moseley
Digital Metaphors
www.digital-metaphors.com