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

How can we pass a String type field value to main report and print it somewhere?


amlan.samanta

Recommended Posts

Normally, we can pass anything from main dataset to a sub dataset or sub report. But the reverse seems to be non-feasible. Attached is a dummy jrxml for more context in defining the problem.

 

Suppose, we have to print the Field3 value in a text field under the main report (See attached jrxml).

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

Hello there, 

I recently managed to pass values from subreport to main report using the "return values" menu.

For example, imagine you have a example_variable in your subreport, just click to return values,

add the variable name, create a variable with the same name in your main report with the parameter calculation = "System"

(cool site https://stackoverflow.com/questions/7348408/returning-a-value-from-sub-report-to-main-report-in-ireport)

 

return_val0.png.995ddd3dee3f3248c81a13a2903d0e8e.png

 

return_val1.png.94cc11252ab96772eac1227a4ecf3792.png

 

Have a great day !

Best regards, Arnaud

 

Link to comment
Share on other sites

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...