Hi,
See this: Possible to pass a date range to a subreport?
You would need to pass shared variable as a parameter from sub report to main report
For Example follow these instructions:
1.Set the shared variable. A shared variable can be set anywhere in the main report or anywhere in any subreport. To set a shared variable called Age you would use the following code:
Shared NumberVar UserAge;
UserAge := {Table1.Age};
""
2. Display or use the shared variable. A shared variable can be processed or displayed anywhere in the main report or anywhere in any subreport. You would share your Age variable like this:
Shared NumberVar UserAge;
UserAge
3. Use your shared variable in formulas or sections anywhere in your report.
Thanks,
DJ