Author |
Message |
nalfein
Groupie
Joined: 07 Jul 2008
Online Status: Offline
Posts: 47
|
Topic: Print repeated Posted: 22 Apr 2009 at 6:53am |
Hello all
I've a proble while printing a report
I'll try to explain as good as I can because the situation is complicated
So in the report I print
Order number (A) / Amount of delivery dates (i.e. if in the order X we've to deliver goods in April and May Cr will print 2) (B) /Client (C) /Delivery date (E)
Field B have this code:
DistinctCount({lines_document.date_delivery})
Field E is {{lines_document.date_delivery}}
My problem is as follow: if in the report i will put fields B or E (one of them is enough) CR will print every single line of the order
Basically if an order contains 5 lines (no matter if they're all delivered at the same date) the report willcontain 5 lines printed (one exactly as the another)
There's a code that says to CR go inside the order, count how many delivery date and print just one each type of them?
I believe that if exist there's a code to insert in fields B and E but what?
P.S.
There's no another field that i can use to print delivery date i must use that above
Thank you in advance for answers
|
IP Logged |
|
DBlank
Moderator
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
|
Posted: 22 Apr 2009 at 7:27am |
You can conditionally suppress the rows or the fields and then the rows on empty depending on exactly what you need. I can't quite figure out your set up and what is duplicating or when you want it to appear or not but here is a process that you may be able to use or tweak.
In each field you can suppress if duplicated (means if the previous record had the same value in this field). Right click on the field and select Format Field, click on the Common tab and check the Suppress if Duplicated box.
Now in the Section Expert, assuming this is on your details row, select details and check the Suppress Blank section.
If all the fields are suppressed because of the previous option then the row will be suppressed also.
if this does not work can you explain the problem and data further or post data examples?
|
IP Logged |
|
DBlank
Moderator
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
|
Posted: 22 Apr 2009 at 8:29am |
In versions X and XI it is under Report Menu > Section Expert or the icon of a hand grabing a line inside a piece of paper.
|
IP Logged |
|
nalfein
Groupie
Joined: 07 Jul 2008
Online Status: Offline
Posts: 47
|
Posted: 22 Apr 2009 at 11:47pm |
Ok almost at the goal
The print now is
Ord. number-- Amount of Delivery date --Client-- Delivery
1234 -- 2 -- John-- 20-May
21-May
20-May
As you can see there's 2 problems yet
1)
If i check "Suppress if duplicated" i cannot se the number, amount, and name client on the second row and i need to see those data
2)
The "Suppres if duplicated" can only check the previous cell but i need that if a record is printed one time it cannot be printed anyway also if is 4 cells away. As you can see in the field delivery I have two same date because of that
I hope that I've been clear enough
Thank you in advance
|
IP Logged |
|
lockwelle
Moderator
Joined: 21 Dec 2007
Online Status: Offline
Posts: 4372
|
Posted: 23 Apr 2009 at 6:17am |
if you only 1 record to display per unique situation, you might try printing the group footer and suppress the detail section all together, this way regardless of the number of items in the order, only 1 row will print on the report.
Hope this fits the requirements.
|
IP Logged |
|
DBlank
Moderator
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
|
Posted: 23 Apr 2009 at 7:27am |
After seeing your data I would agree with lockwelle that you could handle this by grouping on the Ord NUmber then a second group on the date.
Place all the fields you want to see on the GF2 and suppress everything else.
Otherwise you can sort by ord number, and then on date and decide what your conditions are that you you want to see or suppress the record based on what is in the pervious record and then use that logic as a conditional suppress.
|
IP Logged |
|
nalfein
Groupie
Joined: 07 Jul 2008
Online Status: Offline
Posts: 47
|
Posted: 23 Apr 2009 at 8:19am |
Originally posted by DBlank
Place all the fields you want to see on the GF2 and suppress everything else.
Done but worst than before now i can only see one line. Just one and no more. Also if i've 2,3,4,5 delivery date in one order I can see only one row
|
IP Logged |
|
DBlank
Moderator
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
|
Posted: 23 Apr 2009 at 9:07am |
How did you suppress these?
You would need to suppress the items then "suppress blank sections" except for what is on GF2. Cannot use Hide drilldown OK or Suppress No drill down.
Edited by DBlank - 23 Apr 2009 at 9:09am
|
IP Logged |
|
nalfein
Groupie
Joined: 07 Jul 2008
Online Status: Offline
Posts: 47
|
Posted: 23 Apr 2009 at 11:03pm |
Originally posted by DBlankHow did you suppress these?
You would need to suppress the items then "suppress blank sections" except for what is on GF2. Cannot use Hide drilldown OK or Suppress No drill down.
I've just created a Group, put the fields in group footer and in each field i've checked Suppress if duplicated
Just this nothing else but i can see always just one row
I think that i'm near the solution but grrrrr
Thank you for answers
|
IP Logged |
|
DBlank
Moderator
Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
|
Posted: 24 Apr 2009 at 8:29am |
You want your sample data of:
1234 -- 2 -- John-- 20-May 21-May 20-May
To look like
Ord# Amount Client Delivery Date
1234 2 John 20-May
1234 2 John 21-May
Correct?
You should not use the suppress if duplicated.
Create group 1 on Ord#: suppress the field then suppress the section as Suppress blank section.
Create a group2 on Delivery date (set per day). suppress the field then suppress the section as Suppress blank section.
Suppress the Details.
Place the ID#, Amount, client name and date fields on GFooter 2. Do NOT conditionally suppress any of these fields.
Suppress GF1 as Suppress blank section
|
IP Logged |
|
|