截面水晶报告中的抑制线

时间:2014-02-18 12:36:55

标签: crystal-reports

Hi All I have a report having two sub reports
In 1st sub report i have a line in report header and footer.
And in 2nd sub report i have a line in report header and footer.

所以我的2个子报告一个接一个地出现。在这种情况下,我得到两行 一个接一个(一个来自子报告1个页脚,另一个来自子报告2标题) 现在我需要在有第二个子报告的时候抑制第一个子报告中的行

1 个答案:

答案 0 :(得分:0)

I have not tried this solution but I think it will help.

    1] Create a global variable in your second sub report. 
    2] Set its counter to 0 and increment its value with the number of rows you are getting in  2nd sub report. 
    3] On 1st sub report go to format sub report and in suppress formula check whether global variable is greater than 0 if yes then it will suppress 1st sub report.

Not sure with the execution flow of crystal reports but its worth giving a try. let me know if you succeed.

Thanks,
Pratik