Jump to content
We've recently updated our Privacy Statement, available here ×

Pass data from Subdataset to main dataset


gazzer82

Recommended Posts

 Hello All,

I know the sub-report sub-dataset question get's asked a lot so please forgive me for asking again, however i have come up blank when trying to work this one out.

I have a main dataset, and then a sub-dataset on a table.

I would like to hide certain rows of the table base on data in the sub-report.

So ideally i would like to create a new paramater in the main dataset and link that to the correct data in the sub-report, the use a Print When expression on the Detail secrtion. However for the life of me i can't see how to make a linkage that goes that way around. I have links going the other way and they work fine.

Maybe im trying to do this wrong, please feel free to tell me if i am!

Thanks

Gareth

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Create a subreport and setup the parameters to pass into it.  Make sure the subreport is setup as high on the report bands as possible to be sure it runs before the bands to be suppressed are generated.

Have the subreport do whatever calculations you are needing. Pass this information to a variable on the subreport.

Create a matching variable that is blank on the main report.

On the main report under the subreport link properties there is an option to choose your return variables. Set this up with the name of the subreport variable and the name of the main report variable it will apply the value to.

Base your Print When Expression on the variable value.

Link to comment
Share on other sites

  • 1 year later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...