0
votes

I am using crystal report for visual studio 2008, i want to show number of sub reports dynamically i.e. depends on the main reports output, subreports would be generated, all the subreports contain same columns and rows only data is different. e.g. output of my main report is like main report

no. of cities

 3

subreport 1

city1

name | density

footer subreport1

subreport 2

city2

name | density

footer subreport2

subreport 3

city3

name | density

footer subreport3

footer main report

enter image description here

this can be achieved using grouping city name but my question is can we dynamically generate number of sub reports. thank you in advance.

1
As far as I know, this is not possible.Maarten

1 Answers

2
votes

For that you should move the city name/id to the main report and create a sub report to display the details only, which will be fetched using the City name/id passed to the sub report. Your sub report should be placed in the details section, and thus you will be able to generate the report in the format mentioned by you