Checked List Box with Master-Detail

Stimulsoft Reports.NET discussion
Post Reply
dpeel2757
Posts: 19
Joined: Fri Feb 29, 2008 6:09 pm

Checked List Box with Master-Detail

Post by dpeel2757 »

Hi,
I have a standard Master-Detail Report but I am trying to use the Checked List box form to display just the records I select. I have looked at the "Selecting Rows" report in the Demo.exe and have duplicated this report and everything works as long as I only am trying to display the master records. The problem I am having is with the detail records. Whenever I add a databand linked to master databand the report gives me the incorrect results.

Do you have a report, or solution that i can look at that displays a Master-Detail report that allows you to select the Master records using a form and then have the report display just though master records with their corresponding detail records? Thanks in advanced.
Jan
Posts: 1265
Joined: Thu Feb 19, 2009 8:19 am

Checked List Box with Master-Detail

Post by Jan »

Hello,

Please add same condition for detail band. For example:

Code: Select all

DetailBand1.Enabled = CheckedListBoxControl1.Control.GetItemChecked(DataBand1.Position);
Thank you.
dpeel2757
Posts: 19
Joined: Fri Feb 29, 2008 6:09 pm

Checked List Box with Master-Detail

Post by dpeel2757 »

I have tried the following without any positive results. The "CombinedParts" table is the detail table.

When I use
DataCombinedParts.Enabled = CheckedListBoxControl1.Control.GetItemChecked(CombinedParts.Position)
in the Before Print event of the detail band, i receive an error after i have selected the products in the form but before the report is previewed that just says "Object reference not set to an instance of an object".

I am using Version: 2010.1.700 from March 26th 2010.



Jan
Posts: 1265
Joined: Thu Feb 19, 2009 8:19 am

Checked List Box with Master-Detail

Post by Jan »

Hello,

Please check attached report. You can run it in Demo.exe.

Thank you.
Attachments
488.SelectingRows.mrt
(26.82 KiB) Downloaded 203 times
dpeel2757
Posts: 19
Joined: Fri Feb 29, 2008 6:09 pm

Checked List Box with Master-Detail

Post by dpeel2757 »

The attached report gives me a different result but it is still not correct. Select only the Beverages category and the beverages header will be displayed but will list all other details in the report just without the other category headers.

Attachments
489.Selecting Rows Report.png
489.Selecting Rows Report.png (115.29 KiB) Viewed 2355 times
Ivan
Posts: 960
Joined: Thu Aug 10, 2006 1:37 am

Checked List Box with Master-Detail

Post by Ivan »

Hello,

Please check attached report. You can run it in Demo.exe.

Thank you.
Attachments
491.SelectingRows 2.mrt
(26.91 KiB) Downloaded 225 times
dpeel2757
Posts: 19
Joined: Fri Feb 29, 2008 6:09 pm

Checked List Box with Master-Detail

Post by dpeel2757 »

Perfect....always something easy. Thanks a bunch.
Andrew
Posts: 4109
Joined: Fri Jun 09, 2006 3:58 am

Checked List Box with Master-Detail

Post by Andrew »

:biggrin:
Post Reply