kunkasurendra Posted January 31, 2008 Share Posted January 31, 2008 Hi, I have the experience on working subreports using queries,but in my current project,we are using the stored procedures,first we will get the resultset and then placed into the collection object,using colection object we have to generate the subreports, I have done the normal reports using JRBeanCollectionDatasurce,but i am not able to do the subreports, Please can any one help me,how to work on subreports using JRBeanCollectionDatasource. if any one has worked on the subreports using JRBeanCollectionDatasource,please give me the hints ot tell me the procedure how to work. Thanks in Advance,K. Link to comment Share on other sites More sharing options...
junejava Posted February 21, 2008 Share Posted February 21, 2008 For example, if you have $F{cast} as a collection, you can just pass new JRBeanCollectionDataSource($F{cast}) to your subreport. Ex. <subreport> <reportElement positionType="Float" x="20" y="25" width="240" height="20" isRemoveLineWhenBlank="true" backcolor="#99ccff"/> <dataSourceExpression>new JRBeanCollectionDataSource($F{cast})</dataSourceExpression> <subreportExpression class="java.lang.String"><![CDATA["JRMDbCastSubreport.jasper"]]></subreportExpression> </subreport> Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now