Jump to content

problems to generate a subreport


akhanh

Recommended Posts

hi all,

 

i create a subreport under C:ProgrammeJasperSoftreports

 

i create a masterreport to call the subreport.

 

i checked a lot but i get always

net.sf.jasperreports.engine.JRException: Could not load object from location : .Liste.jrxml

at net.sf.jasperreports.engine.util.JRLoader.loadObjectFromLocation(JRLoader.java:266)

at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluateSubreport(JRFillSubreport.java:311)

at net.sf.jasperreports.engine.fill.JRFillSubreport.evaluate(JRFillSubreport.java:260)

at net.sf.jasperreports.engine.fill.JRFillElementContainer.evaluate(JRFillElementContainer.java:274)

at net.sf.jasperreports.engine.fill.JRFillBand.evaluate(JRFillBand.java:403)

at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillColumnBand(JRVerticalFiller.java:1380)

at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:692)

at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:255)

at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:113)

at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:791)

at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:714)

at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:89)

 

 

 

The file .Liste.jrxml is in the same folder of the masterreport.

Can help somebody?

Thanks

Link to comment
Share on other sites

  • Replies 9
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

jasper needs the "Liste.jasper" file and not the .jrxml. once you compile the report (the jrxml file) a file with the same name but .jasper is created in iReportxxx dir. just copy that file to where you point the report to, or point the report to the correct location.
Link to comment
Share on other sites

hi,

it works now after the svenn's post.

i work under window and i wrote for subreport expression

"C:\Programme\JasperSoft\reports\a1.jasper".

After i wrote "C:/Programme/JasperSoft/reports/a1.jasper" it works.

 

Now i have a new problem. i will display the detail datas of the subreport in the masterreport. But it shows all bands of the subreport without detail band. i need the detail band informations to print in the masterreport. what can i do?

 

Thanks

Link to comment
Share on other sites

i try again:

e. g. i add in the detail band of my subreport the static text "detail" and in the page Header of my sub report the text "header". now i run the masterreport.

in the pdf file i see only the text "header". the information in the detail band are not print in pdf.

 

I think the reason is:

if i open in the masterreport the preferences of the subreport and see in the tab Subreport->connection/datasource i must add a connection. if it is empty the detail band are not print. what can i write?

 

Thanks and sorry about my perfect english

Link to comment
Share on other sites

i try again:

e. g. i add in the detail band of my subreport the static text "detail" and in the page Header of my sub report the text "header". now i run the masterreport.

in the pdf file i see only the text "header". the information in the detail band are not print in pdf.

 

I think the reason is:

if i open in the masterreport the preferences of the subreport and see in the tab Subreport->connection/datasource i must add a connection. if it is empty the detail band are not print. what can i write?

 

Thanks and sorry about my perfect english

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