Jump to content
Changes to the Jaspersoft community edition download ×

sean_wdg

Members
  • Posts

    10
  • Joined

  • Last visited

sean_wdg's Achievements

Apprentice

Apprentice (3/14)

  • Week One Done
  • One Month Later
  • One Year In
  • First Post Rare
  • Collaborator Rare

Recent Badges

0

Reputation

  1. I'm having the same problem. Except I have multiple reports, with each having the option to export to .pdf or .xls. They all export fine to .pdf, only a couple will have column headers when exporting to .xls - and I can't see any obvious differences between the reports that show column headers and those that don't. I'm using GlassFish 3.0.1 - do you know where would I look to find the same files you highlight? Thanks.
  2. Ugh. What is it with me and rookie mistakes? I have my JSF project pulling the .jasper files from a specific locations. To that end I have my iReport compiling the reports to that particular file location. At some point in the past week I was fiddling with another report and didn't want it to go to the same location as my project reports ... so I changed the compile location in iReport. It was after that when I created all the scriptlet functionality. When I added the scriptlet functionality and compiled the reports, I forgot to change the compile location back to the project report folder. The reports were compiling elsewhere. So my project was using the old versions of the report files. Updating the compile location in iReport and recompiling the reports fixed the issue. The .jar file in my library works fine.
  3. I'm using JasperReports 3.7.6 with NetBeans 6.9.1 and iReport 3.7.6. I have a report that uses scriptlets. When I run it from iReport everything is fine because I can tell iReport where to find the .jar file with the scriptlets. When I run that same report from a JSF-2.0 application the fields that rely on the scriptlet are not being populated correctly - i.e. the scriptlet isn't being called. I've tried putting the scriptlet in the project's library folder and I've tried copying the package containing the scriptlet into the project. Neither has worked. I'm not sure how I can get the report to call the scriptlets when it is run from my JSF project. Can anyone shed some light on this for me?
  4. Where is this jasper sample? I can't find it, and I'm having difficulty generating a subtotal in the group footer. Thanks.
  5. I've resolved this problem. I changed $P{DB_TO_USE} to $P!{DB_TO_USE}. "The exclamation point tells JasperReports to don't bind the parameter to an SQL parameter (using the question mark (?) ...), but rather to calculate the value of the parameter and treat it as a raw piece of query." (Ultimate Guide to iReport, Third Edition, by Giulio Toffoli, p. 116)
  6. I need to be able to run my report from different databases with the same structure, but different data (for different users). I have tried to pass the database name as a parameter in the <queryString>: <queryString> <![CDATA[sELECT db_field1, db_field2, db_field3, .... FROM $P{DB_TO_USE}]]> </queryString> Whether I defined the parameter DB_TO_USE as a string or as net.sf.jasperreports.engine.JRDataSource, I received errors when running my program. How can I design my report so that the name of the database is a parameter passed at runtime? Post Edited by sean_wdg at 01/13/2011 20:02
  7. I'm trying to use JasperReports to create the reports I will use in a web application. I'm developing in JSF 2.0 using NetBeans 6.9.1 and a Glassfish 3.1 server. I created a very simple report with iReport 3.7.6 - one record! I experimented with a simple resource bundle, making one label a text field which gets filled from the resource bundle properties file. All works well when I run the report from iReport. But when I try to run the report from my web application, I'm getting the error that the bundle cannot be found. I named my resource bundle Bundle, and get his error message: SEVERE: javax.faces.FacesException: #{userReportBean.runReport}: java.util.MissingResourceException: Can't find bundle for base name Bundle, locale en_US I put a copy of the properties file in a report within my project, and pointed a classpath to it in iReport. I looked at the xml for the report. It doesn't seem like my web application will know where to look for the properties file, because the classpath isn't included in the jrxml file. How can I tell my program to find/use the resource bundle for this report?
  8. Have you found a solution to this problem? I've been trying to display a .pdf in a web page using JSF and have an issue with a file not found error. I'm going about it differently, creating, compiling, and exporting the .pdf to a file, then using <h:panelGrid> and <iframe> to display the .pdf. I cannot, however, get the .pdf to display without manually hitting reload inside the frame. The report gets created, but no matter what I've tried I cannot get the program to wait long enough for the file to be written before attempting to display (I have a loop that tests whether the file is created and returns a boolean when it is). Any insight you've gained would be a big help. Thanks.
  9. Did you ever find a solution to this problem? I've had the same trouble. My only solution has been to use absolute paths in my development code, but that won't fly in production. If you have a solution I would love to hear it. Thanks!
  10. I am trying to display a report on a webpage using JavaServer Faces (JSF). I can create the report without a problem, I can even export the .pdf file to the appropriate directory. I cannot get the webpage to wait for the file to be created before trying to display it. The way I am displaying the report is in a <h:panelGrid>, the rendered attribute is linked to a boolean variable in the backing bean. The boolean tests whether the file is created, and returns true when the file is created. My problem is that, despite the boolean check, when the panel gets displayed and tries to access the report from the directory location, it returns an HTTP 404 file not found error. If I run the program in debug mode, with a breakpoint at the method that checks the file and returns the boolean variable, that slight pause seems to be enough to allow the report to be written to the directory and it gets read and rendered on the screen no problem. I have tried to implement delays in my program, even having the program wait a few seconds before returning the bolean to display the <h:panelGrid>, but I still get the error. Is there some way in JasperReports to verify that the report is written and located in the appropriate directory before moving on to the display method? Thanks.
×
×
  • Create New...