Require multiple pages for a single bar chart in Crystal Reports 2008

I am creating a histogram where the values ​​are the maximum of the AVE_ZSCORE field, and this is set as "when changing" the PARTICIPANT_CODE field. At any moment, I could have up to 250 entries in this diagram, and therefore I need to split the diagram into several pages. However, this number of records is dynamic and can vary from 150 to 250 records.

I tried the solution in this thread http://www.tek-tips.com/viewthread.cfm?qid=1257385 , and I followed the instructions as well as I understood (please remember that I am completely new to Crystal Reports). I created a formula, pasted it into the details section, which I then suppressed, then entered the group into this formula, and inserted the chart into the group footer section. The formula I am currently using (which I called the "chart") to test this on 4 pages:

WhileReadingRecords; numbervar cnt: = cnt + 1; if cnt is in 1 to 2, then 1 else if cnt is in 3-4, then 2

My problem is that the result of this result consists of 3 graphs of the following instead of 2 graphs containing 2 entries:

  • group output 0.00, which has all 4 entries (B2, BB, KK, MM) in one graph
  • group output 1.00, which has only one of the entries (BB)

  • group output 2.00, which also has only one record, which is the same record of the previous chart (BB)

If I change the formula to display as follows:

WhileReadingRecords; numbervar cnt: = cnt + 1; if cnt is in 1 - 4, then 1

Then the output becomes

  • group output 0.00, which has all 4 entries in one chart (B2, BB, KK, MM)
  • group output 1.00, which has one record (BB)

So, firstly, I do not understand the formula that I use or how it works, and secondly, I have no idea how to do this, so that I can easily indicate the number of columns in the diagram

+7
source share
1 answer

Unfortunately, it's hard to say something without a complete understanding of your report layout. Some screenshots will easily complicate. Since nothing is specified, I expect that your report will only have one (mentioned) group.

To achieve your goal, you must display your chart as many times as different group values ​​have. Here's what the group details section looks like. No footer or header. Because the chart cannot be added to the details section, an additional stub group must be created. Thus, the result will be two groups:

  • The outer group (# 1) will be based on your formula field and does not have a header / footer
  • The inner group (# 2) will be used to display the chart in the header or footer

Group No. 2 can be based on the same formula as Group No. 1 (or any other field of the formula / it does not matter).


Btw, instead of calculating the score manually, as in your code

WhileReadingRecords; numbervar cnt := cnt + 1; 

You can use the current full fields with the type of total score in any field that you want to control. These fields are very customizable, so you would like them.

0
source

All Articles