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

augarte

Members
  • Posts

    270
  • Joined

  • Last visited

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Downloads

Everything posted by augarte

  1. I answer myself because I found a solution. Maybe someone could find this helpfull select t1.*, (select sum(Itr) from cllItrFlwAud t2 where t2.Dva<=t1.Dva) [Total] from cllItrFlwAud t1 This query creates a new column "Total" where I calculate what I was asking for in the previous post.
  2. Hi, I want to do the following in one of my reports: Date Interest Total 2012-01-01 1 1 2012-01-02 2 3 2012-01-03 3 6 2012-01-04 4 10 2012-01-05 5 15 2012-01-06 6 21 As you can see, the value of "Total" column for each row is the sum of the actual value and previous values of Interest column. For row 1 is 1 For row 2 is 1+2 Fro row 3 is 1+2+3 and so on... My problem is that Total column is not stored in database so I need to calculate this value somehow. Don't know if creating a variable in iReport is possible, or otherwise have tu use some Sql special function in my query to achieve what I want. Does anybody know how can I do that? Thanks in advance, Regards.
  3. Hi, How is the "Subreport Expression" defined in your test_report.jrxml file? I always define the subreport expression as follows: $P{SUBREPORT_DIR} + "NotificationSubRep.jasper" In your case should be: $P{SUBREPORT_DIR} + "test_subreport.jasper" Then you have to set a value for SUBREPORT_DIR parameter. I don't think '/' is a good value for it. I'm not sure if setting this empty will work. You can try setting it empty and if it doesn't work try setting the following: "..//reports//". I don't use JSF nor IceFaces, but I'm launching subreports in a web application this way and this works for me. Hope this helps. Regards.
  4. Hi, You can see all the datasources clicking in "Report Datasources" icon, then just select the obsolete datasource and click in "Delete" button. You can also modify them selecting "Modify" option. I attach an image. Hope this helps. Regards
  5. When setting a font to a field, does anybody know if it is possible to set double size? I have an algothim where I calculate the font size to fit the report in one page, and I reduce the font size one by one (10, 9, 8, 7...). I would like to know if it is possible setting font sizes as follows: 10, 9.5, 9, 8.5, 7, 7.5... Any help will be very appreciated. Regards!
  6. Hi, Sanda, I forgot to tell you what was the problem. After hours of investigation, we found out that the problem wasn't with jasper. Our client uses Citrix environment to run the application and the printers the user was using to print the jasper files wheren't supported by Citrix. So we think the problem is related to printers and everything is ok with jasper. Thansk again and regards! :-)
  7. Hi, I have tried viewing the .jasper file you attached with the JasperViewer and exporting it to pdf and in both cases I get the same error: net.sf.jasperreports.engine.JRRuntimeException: Unknown hyperlink target 0 Maybe you have some problem with the jasper file... are you using any hyperlink? Try removing it and check if you still have the same problem. * I edit the post because maybe the problem is mine because the jasper version I'm using is older than yours... which version are you using? Post Edited by augarte at 03/20/2012 14:55
  8. I'm sorry but I can't figure out what can be happening. Maybe if you post the jrxml file I can check it but I'm afraid I won't be able to reproduce it cause I guess you execute it with a database connection. Another option could be to attach the .jasper file. You can check it with the JasperViewer to see if it is paginated or not. If you attach it I'll have a look to it and try to help.
  9. But where/how do you visualize this report? If I see the code I can figure out that it is in a web application. I have never used it but maybe what you need is to use JRHtmlExporter instead of JRPdfExporter: http://jasperreports.sourceforge.net/api/net/sf/jasperreports/engine/export/JRHtmlExporter.html Another test you can do is to export your report to a pdf file and check if it is ok openning with Acrobat Reader or other software to read pdf files. JRPdfExporter PdfExporter = new JRPdfExporter (); InputStream is = getClass().getResourceAsStream("../report.jasper"); report = (JasperReport)JRLoader.loadObject(is); PdfExporter.setParameter (JRExporterParameter.JASPER_PRINT,report); PdfExporter.setParameter (JRExporterParameter.OUTPUT_FILE_NAME, "Report.pdf"); PdfExporter.exportReport (); This way you can know if the problem is with jasper or you just have a problem visualizing the report from your application. Hope this helps. Regards.
  10. The only difference is that when you check this option it adds the following attribute in the jrxml file: isIgnorePagination="true" Are you sure the .jasper file is the one created after unchecking this option? How do you generate the report in your application? Which output are you using? This information could be usefull to find out a solution.
  11. Hi, In your report properties, check how is "Ignore Pagination" option. If you want to create the report in different pages this option should be unchecked. Hope this helps. Regards
  12. Hi gabri, Your problem is in the jrxml file with the definition of the fields. You have created three fields but no description is defined for them so the report does not know where to get the values from. and it shows null. I made the following modification in the definition of the fields: <field name="nombre" class="java.lang.String"> <fieldDescription><![CDATA[nombre]]></fieldDescription> </field> <field name="edad" class="java.lang.String"> <fieldDescription><![CDATA[edad]]></fieldDescription> </field> <field name="domicilio" class="java.lang.String"> <fieldDescription><![CDATA[domicilio]]></fieldDescription> </field> I have tried it with your source code and it works ok. I attach the corrected jrxml file. Hope this helps Regards.
  13. Hi Frankie, If you go to your iReport installation directoy and edit de "ireport.conf" file which is inside "etc" folder you will see the following line: default_options="-J-Xms24m -J-Xmx512m The -Xmx option sets the maximun memory asigned for java (Java Heap Space), increasing this iReport should run faster. You can try increasing to 1024m and if this doen't work you can try with 2048 (note that if you set this space while you are running iReport will take 2Gb of RAM). After editting the file you have to close iReport and start it again to take this modification. Hope this helps. Regards.
  14. Hi, If you select a band will see that you can set "Print When Expression" for the whole band. Don't know if this will work (putting table footer in a different band) but you can try. Hope this helps. Regards.
  15. Hi, As the reference says, you need to add the jar with the bean classes to the lib directory. I understand you have two different options: For doing that in iReport, go to "Tools-> Options". Then select CLASSPATH tab and you can add the jar from here. If you want to create the report in Netbeans using the iReport plugin is a little bit different. You have to go to "Tools->Options->iReport" and then select the CLASSPATH tab and add the needed jar. Hope this helps. Regards.
  16. Hi, Have you tried setting a page break between each subreport? Hope this helps. Regards.
  17. I rfkrocktk, This is not that difficult. I don't know if there is any other easier way for doing that but I had an issue similar to yours and what I did is to create one report for each list and then create a main report with subreports. In your case, you should create 1 main report with 5 subreports in the detail band (one subreport for each list). Hope this helps. Regards.
  18. Hi Rick, You select your field and in the right side of iReport inside the properties (Text properties) you have one that is "Horizontal Alignment". Here you can select Left, Right, Center of Justified. I attach you an image. Hope this helps. Regards
  19. Hi, Yes, you should use pipes to be interpreted as 'OR' condition. But I think you don't need "Print When Expression" option in this case, because this one is used to print a field or not depending on a expression. You should do it with three different textfields and editting directly the expression of each textfield: (($F{Tax}.equals("01")) ? $F{VA} : "") (($F{Tax}.equals("02")) ? $F{VAINT} : "") (($F{Tax}.equals("03")) ? $F{VARES} : "") I don't know if you can combine the three expressions in one with pipes. You can try the following but not sure if this will work (two options): (($F{Tax}.equals("01")) ? $F{VA} : "") || (($F{Tax}.equals("02")) ? $F{VAINT} : "") || (($F{Tax}.equals("03")) ? $F{VARES} : "") (($F{Tax}.equals("01")) ? $F{VA} : "") + (($F{Tax}.equals("02")) ? $F{VAINT} : "") + (($F{Tax}.equals("03")) ? $F{VARES} : "") I think the second option is better because here you are concatenating three strings but only one of them will have a value so basically you are concatenating two empty string with the value of the field you want to add in your report. Hope this helps. Regards. Post Edited by augarte at 03/12/2012 14:24
  20. Hi, What do you want to do excatly? I undestrand you have 3 textfields: "VA", "VAINT" and "VARES" but what do you want to to with them exactly? You have 3 different cases and want to print a different value in each case or what? Regards.
  21. You say "I have already include the parameters I want to pass"... where did you include these parameters? Did you create them manually in the subreport? I don't know what do you mean with that... I only used 'Copy from master' option for my subreports and the parameters of the subreport where created automatically and defined as it is shown in the picture.
  22. Hi, You don't need to use any function to display the values of the parameters of your main report in the subreport. You just have to select the 'Parameters' option in the subreport properties and then select "Copy from master" option. This will create the parameters in your subreport and then you just need to drag and drop the needed parameters in the band you want to display them. I send you an attached image to check where is this option. Hope this helps. Regards.
  23. Hi, Ok, I'll try this option and I'll let you know. Another posibility we have been thinking about is that the problem could be with the printer. If the user tries to print with any other printer it works of but if the default one is a multi-functional printer is failing in some cases. I'll investigate about both options. Thanks again! Regards
  24. Hi Shertage, Thanks for your reply. I've used this function but for printing reports from a network printer specified by the user. In this case I need to print it from the default printer. What happens if you do not specify a printer name? Does it print the report from the default printer? Thanks in advance. Regards. Post Edited by augarte at 03/09/2012 14:36
  25. Hi, Here you have a very helpfull example of how can you compile & fill the report and the export it to different formats. java.dzone.com/articles/java-reporting-part-2 Feel free to ask if you have any doubt after reading it ;-) Hope this helps. Regards
×
×
  • Create New...