I have a report in which I want to create two groupings so I add two group headers and two group headers. When I user the designer this seems to work well. However now I'm trying to dynamically generate the report (dynamically build up the controls) from information in a database and the footer properties do not seem to render correctly. Both headers footers seem to be associated with the inner group even though I’m careful to set the GroupHeader property. This means the out group header and footer are printed every time the inner group changes and not just every time the outter group changes.
I should get a grouping like:
-Group header outer
-Group header inner
-Detail
-Detail
-Group footer inner
-Group header inner
-Detail
-Detail
-Group footer inner
-Group header inner
-Detail
-Detail
-Group footer inner
-Group footer outer
But instead I get (note all the extra "Group header outer" "Group footer outer"):
-Group header outer
-Group header inner
-Detail
-Detail
-Group footer inner
-Group footer outer
-Group header outer
-Group header inner
-Detail
-Detail
-Group footer inner
-Group footer outer
-Group header outer
-Group header inner
-Detail
-Detail
-Group footer inner
-Group footer outer
What could be causing this?
Group footers & headers
Group footers & headers
In fact this problem was due to my (mis)use of anonymous delegates. I've fixed problem now and every thing seems to be working as expected.
Group footers & headers
If you have any questions, please contact us.
Thank you.
Thank you.