Page 1 of 1

Omit header if data is empty in master detail report

Posted: Tue Mar 12, 2013 3:31 pm
by chriga
Hi,
I have a master detail report with header and data. I have attached an example report (Report.mrt).
Screenshot1.png
Screenshot1.png (29.85 KiB) Viewed 3649 times
If data is existing all seams to be ok:
Screenshot2.png
Screenshot2.png (6.75 KiB) Viewed 3649 times
But if the data is empty the header is still shown:
Screenshot3.png
Screenshot3.png (5.26 KiB) Viewed 3649 times
How can I prevent showing header if data is empty?

Best regards,
Chris

Re: Omit header if data is empty in master detail report

Posted: Wed Mar 13, 2013 7:48 am
by Alex K.
Hello,

We couldn't reproduce the issue.
Can you please send us a test data for your report.

Thank you.

Re: Omit header if data is empty in master detail report

Posted: Wed Mar 13, 2013 10:42 am
by chriga
Hi,
I have attached a VS project that creates example data for the report.

Best regards,
Chris

Re: Omit header if data is empty in master detail report

Posted: Wed Mar 13, 2013 1:22 pm
by HighAley
Hello.

You have data in the Data2 band and the header is printed.
In this report you should swap Data2 band and HeaderBand2.

Thank you.

Re: Omit header if data is empty in master detail report

Posted: Thu Mar 14, 2013 8:29 am
by chriga
Great! This works perfectly! But now, I have another case, where I want to omit the header and I don't know how.
Screenshot1.png
Screenshot1.png (22.39 KiB) Viewed 3629 times
If all data exists then there is no problem:
Screenshot2.png
Screenshot2.png (4.35 KiB) Viewed 3629 times
But if the data is null the header is still shown:
Screenshot3.png
Screenshot3.png (3.76 KiB) Viewed 3629 times
I can remove the second header if I create an empty collection, but the first header still exists:
Screenshot4.png
Screenshot4.png (2.67 KiB) Viewed 3629 times
How can I prevent showing header if data is empty in this case? For better understanding I have attached an example report within an example project.

Best regards,
Chirs

Re: Omit header if data is empty in master detail report

Posted: Fri Mar 15, 2013 10:04 am
by HighAley
Hello.

We have reproduced your issue.
We will let you know when it will be fixed.

Thank you.

Re: Omit header if data is empty in master detail report

Posted: Tue Apr 09, 2013 11:32 am
by HighAley
Hello.

We have made an improvement. You could read more about this problem on our Knowledge Base.
It will be available in our next prerelease build.

You should add next code in your project:

Code: Select all

Stimulsoft.Report.Dictionary.StiBusinessObject.FieldsIgnoreList["Test.Result"] = null;

report.Load("Report.mrt");
report.RegBusinessObject("Tests", tests);
Thank you.