Jump to content

2006 IR Open Discussion

Members
  • Posts

    776
  • Joined

  • Last visited

 Content Type 

Forum

Downloads

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Security Advisories

Events

Profiles

Everything posted by 2006 IR Open Discussion

  1. By: Eric Everman - eeverman Horizontal Alignment 2003-03-24 15:26 Hi- I am just coming back to JR for a new project - thanks for this great reporting library. I am trying to align labels and content, where the content can be multiple lines like this: label: content line 1 content line 2 label: content line 1 ...etc... My problem (as has been discussed in other posts) is that "Float" positioning does not push items down if they are not below each other horizontally, so my labels and content end up misaligned. I know its possible to use an invisible line under each label/content pair to force the behavior I need, but I think this has got to be a common problem - couldn't there be a cleaner (and more obvious) solution? It seems like there are many ways the API could be modified to allow for this behavior, the simplist being to allow "Float" to push an item down even if it does not 'overlap' horizontally - this seems to me to be the intuitive interpritation of how Float would work. Alternatively, a "FloatAll" value could be added that would have the new behavior. Even better would be some type of sub-band that could have a streachable height, allowing its contents to occupy their own space - like a mini subreport. Any possibility of making this issue easier to deal with in future releases? Thanks for your help, Eric Everman By: Teodor Danciu - teodord RE: Horizontal Alignment 2003-03-25 00:50 Hi, I'm thinking about allowing the use of multiple <band> tags in a report section, in order to eliminate the need for dummy groups as explained in the "Tips&Tricks" section on the site. This would also solve the alignment issue that you mentioned here. But since this is a major change, it will affect those who use the JasperReports API. The existing XML designs will remain compatibles, but those who create report designs programmatically will probably be affected. This is especially the case for the GUI tools like iReport. I have to ask or at least worn them about such changes. Thank you, Teodor
  2. By: Gregory A. Swarthout - gswarthout Any word on when new version will come out? 2003-03-25 10:31 Please, Teodord? By: Teodor Danciu - teodord RE: Any word on when new version will come out? 2003-03-25 13:19 Hi, The 0.4.6 version will be out in one or two weeks. But what exactly do you expect from it? Is there some feature you are waiting for in particular? Thank you, Teodor By: Gregory A. Swarthout - gswarthout RE: Any word on when new version will come ou 2003-03-25 14:29 > Hi, > > The 0.4.6 version will be out in one or two weeks. > But what exactly do you expect from it? > Is there some feature you are waiting for in particular? I'm most interested in having the issues/bugs I've point out addressed. I'm sure I'll be happy with new features as well :) Greg
  3. By: Gregory A. Swarthout - gswarthout Any idea of when next version is released? 2003-03-19 11:34 N/T By: Teodor Danciu - teodord RE: Any idea of when next version is released? 2003-03-25 14:23 Hi, In one or two weeks. Thank you, Teodor
  4. By: Edgar Dollin - edollin imageMap JRHtmlExporter 2003-03-19 11:14 In your webapp examples you have an image which is fully resolved in WebappReport.xml. In the JRHtmlExporter it is looking for an image map which you supply empty. Looking at the code it is not clear what the purpose of the image map is. Could you please explain. Many thanks Edgar By: Teodor Danciu - teodord RE: imageMap JRHtmlExporter 2003-03-25 14:21 Hi, We supply an empty map to the built-in HTML exporter so that it can place the images in this map. After the report is generated, we have a special servlet/jsp that can deliver the images based on their names from this in-memory image map. Why? without the map, the exporter would have to put the images somewhere on disk and the web server would have to deliver them from that location. In web environment, generating files on disk could get very tricky especially when dealing with simultaneous requests. But if the reports are generated in memory, then the output of different request can be separated using the sessions. Simply put, by default, the HTML exporter generates an HTML file on disk accompanied by a directory containing all the images as files. But if you don't want to generated files on disk (and in Web you don't want to), then you give it a map to put the images in and a string buffer to put the HTML text. Then you deal with this in-memory content in your servlets or JSPs like you can see in the "webapp" sample. I hope this helps. Teodor
  5. By: Wesley Ng - abrabra Two different tables 2003-03-18 20:49 If I wish to have a report with 2 tables with different no. of columns, can I do so? Can I use subreport for that even the detail display on both the table does not really related? Regards By: Teodor Danciu - teodord RE: Two different tables 2003-03-25 14:15 Hi, If you need to display in the same document data that comes from two tables that are not related, then I'm sure subreports are the only solution. But I'm not sure I understand what you mean by "different no. of columns". If your document requires you to dynamically decide what column you display, then we might be talking about dynamic report designs already. This could be achieve by dynamically creating report designs using the JasperReports API. This can be seen in the "noxmldesign" sample provided. I hope this helps. Teodor
  6. By: Erich Kilmer - ekilmer Why can't JR do a border around text in HTML? 2003-03-18 05:39 Just trying to understand why JR can't do a border around multiple text elements in HTML. Since most structuring in HTML is done in <table>s why is it that an attribute can't be converted over to border=1? I am sure that there is more to it and I probably over simplify it. If there is a way to do this, would someone please post a code snippet. I can understand why HTML can't do more advanced shapes but a border around a few rows with multiple cells is pretty basic. TIA By: Giulio Toffoli - gt78 RE: Why can't JR do a border around text in HTML? 2003-03-18 07:45 HTML exporter shipped with JR not support rectangle. Giulio By: Teodor Danciu - teodord RE: Why can't JR do a border around text in HTML? 2003-03-25 14:08 Hi, Text elements in JasperReports do not have a border of their own. At first, I was tempted to say: "We'll add one." Some sort of a "pen" attribute in the <textElement> tag. But then things are more complicated as only <graphicElements> have the ability to stretch based on the "stretchType" attribute and without that text elements will still lack flexibility when it comes to accommodating their size based on other elements size. So let's just stay where we are and say that when it comes to border around elements, you should always use either rectangles or horizontal and vertical lines. And this is when the HTML problem intervenes. The current HTML exporter simply ignores lines and rectangles. But the new one, which I'm preparing these days, will at least know how to handle horizontal and vertical lines and rectangles as long as they do not overlap with other elements. With this approach, the solution that employs rectangles to draw the border will still remain out of the question as it would imply that the text elements overlap the rectangle. But if you use lines to draw the border around, then starting with the 0.4.6 version, it will also work in HTML and XLS format. Thank you, Teodor By: Erich Kilmer - ekilmer RE: Why can't JR do a border around text in HTML? 2003-03-18 10:19 OK. Well if you ever are looking for nice features to add you might consider adding a way to put a group box around multiple rows of text. Thanks! By: Teodor Danciu - teodord RE: Why can't JR do a border around text in HTML? 2003-03-25 14:13 Hi, I agree. But the problem is that HTML border does not even behaves the same way across different platforms and different browsers. Until then, the new version will bring an enhanced HTML exporter that would know how to treat at least horizontal and vertical lines, as well as rectangles. The only condition is for the elements to not overlap. We cannot have overlapping elements in HTML, at least not without the intensive use of CSS. But CSS compatibility is another sad story. So, if you'll use horizontal and vertical lines to put border around your elements, beginning with the next version, they will also appear in HTML. Thank you, Teodor
  7. By: Sonia Marcela Benavides - sobenavi How add sheet to xls report? 2003-03-18 07:37 I'm creating a report and exporting a file with xls format.. there a property called IS_ONE_PAGE_PER_SHEET in the JRXlsExporterParameter class wich add a sheet for every page in the report. How can i decide when add a sheet, like having groups of pages and i decide when generate a new sheet.... how can add sheets in jasper reports? Thanks a lot By: Teodor Danciu - teodord RE: How add sheet to xls report? 2003-03-25 14:10 Hi, The built-in XLS exporter creates exactly one sheet per page, in the original document. I cannot create one sheet for multiple pages. There is a one-to-one relation. Page breaks can be forced using the "isStartNewPage" attribute of the group. But there is no way you could prevent a group from overflowing on multiple page and resulting in more than on sheet. Which brings me to this idea: Use a fairly large enough page height to make sure no group will spread across more than one page and this way you'll have a page break only when your group starts. But this is a trick that I don't think was tested before and is not very nice. I hope this helps. Teodor
  8. By: Erich Kilmer - ekilmer Why won't my rectangle show? 2003-03-14 09:08 I am trying to build a report that has text within a rectangle. After compiling I build the report and I can see the text but not the rectangle. I suspect that the text overlaps the rectangle. Could this keep the rectangle from displaying? Is there a way to make the rectangle display even with the text overlapping it? This would be good for debugging the report design. Also since a rectangle is in a band, can I have two rectangles side by side in the same band? TIA By: Erich Kilmer - ekilmer RE: Why won't my rectangle show? 2003-03-14 12:02 Let me rephrase that. My rectangles do not have a border. I was looking at the HyperlinkReport sample. If you look at them in PDF they have a nice border around the rectangle and the entire rectangle has a solid color background. However if you look at the HyperlinkReport HTML page then the nice border is missing and the solid color background is only on the first row. This is what was throwing me off. I was using the example XML and looking at the PDF examples and couldn't understand why my HTML looked different. So, is there anyway to get the rectangles with borders in HTML? By: Erich Kilmer - ekilmer RE: Why won't my rectangle show? 2003-03-14 12:45 Also looked at the ShapesReport. In PDF all the rectangles and ellipses look good but in the HTML they are all missing. Can you do graphic elements in HTML? I realize there is only so much you can do in HTML but you could do rectangles with borders right? We need to be able to do this. Using JR 0.4.5. By: Teodor Danciu - teodord RE: Why won't my rectangle show? 2003-03-16 02:09 Hi, The lines, rectangles and ellipses are ignored by the built-in HTML exporter. It does not know how to handle them. Some users put thin empty static text elements to draw lines and rectangles. I hope this helps. Teodor By: Erich Kilmer - ekilmer RE: Why won't my rectangle show? 2003-03-17 05:49 Thanks for the response. Can you put text inside a "rectangle" built from a "thin empty static text element"? Anyone have a XML snippet of this I can try? By: Teodor Danciu - teodord RE: Why won't my rectangle show? 2003-03-25 13:54 Hi, I'm thinking about supplying a sample that would demonstrate how to create tables. Hopefully it will be available with the new version. Thank you, Teodor
  9. By: shardy - shardy why I can't run the demo of subreport? 2003-03-17 01:44 when I run the demo of subreport.the has some error.The System warning and exit the system.and print Valid documents must have a <!DOCTYPE declaration. By: Teodor Danciu - teodord RE: why I can't run the demo of subreport? 2003-03-25 13:53 Hi, Can we see the entire exception stack trace? Thank you, Teodor
  10. By: jose - jose4 getBeanArray Doubt 2003-03-15 21:56 Hi Everybody! In the example provided,there is a call to the function,getBeanArray(). So while using subreports,can i call this function more than once? ie one getBeanArray(),for each subreport? since there will be only one BeanApp file. So while using subreports,can i call this function more than once in the main Application file? Thanks for the help By: Teodor Danciu - teodord RE: getBeanArray Doubt 2003-03-25 13:48 Hi, You can call this method as many times as you want to. But I'm not sure what you want to achieve, because as you can see this method will always return the same thing. Do you want all your subreports to display the same thing over and over again? I hope this helps. Teodor
  11. By: jose - jose4 Dynamic report designing 2003-03-09 02:42 Hi Everybody!! 1.Is draft mode printing possible ;ie,here I use a dotmatrix printer and can I convert the pdf output to draftmode ie the normal dos style? 2.Can we dynamically change the report design; ie at runtime? 3.can we dynamically pass a date or string as parameter to see a specified report on a particular date? Thanks in advance By: Teodor Danciu - teodord RE: Dynamic report designing 2003-03-13 13:34 Hi, 1. No. We need a simple text exporter to produce text files. Any volunteers? 2. Yes. Check the "alterdesign" sample that comes with the 0.4.5 version 3. You can pass anything as a parameter. But I'm not sure what you mean... Thank you, Teodor By: jose - jose4 RE: Dynamic report designing 2003-03-15 01:19 """can we dynamically pass a date or string as parameter to see a specified report on a particular date? """" What I meant was that if I want to see a sales report of a particular date, can I pass that Particular date as parameter? Thanks Teodor By: Teodor Danciu - teodord RE: Dynamic report designing 2003-03-25 13:47 Hi, You can pass any object as a parameter. And you can even use some of those parameters to retrieve data from the database. Check the "jasper" sample and the "query" sample to see how parameters can be used in the SQL query. I hope this helps. Teodor
  12. By: Navaneetha Krishnan J - navaneethanj Difference between Fields,Variable,Parameters 2003-03-13 23:21 Dear all, Can any body brief me about the difference between Fields, Variables and Parameters in the sense of following 1. advantages of each one. 2. usage by the developer of each one. 3. usage by the jsper of each one. Thanks for your help in advance. Regards, Navaneethan. By: Teodor Danciu - teodord RE: Difference between Fields,Variable,Parameters 2003-03-25 13:42 Hi, Have you read this? http://jasperreports.sourceforge.net/tutorial/index.html I hope this helps. Teodor
  13. By: genri como - gcomo01 subreport position 2003-03-25 11:02 Hi, I have got a number of subreports and am placing them in a master(skeleton) report.What's the relative position(s) i need to place them.I currently am placing them all in the 'detail' but they overlap.Any idea would be appreciated. thanks Genri ! By: Teodor Danciu - teodord RE: subreport position 2003-03-25 13:11 Hi, You put them one after the other and use positionType="Float" for each of them. I hope this helps. Teodor
  14. By: Javier Castañ³®- javiercv Strategies for large reports 2003-03-24 07:05 Hi! We face the old problem of generating large reports. We're dealing with the famous -Xmx parameter, investigating about the 8192 pages PDF iText limit, and paging result sets. Our customer is getting impatient and wants to generate each day larger, and larger, and larger reports. We'd like to hear your suggestions, we're collecting them in http://www.lucidees.com/~javiercv/jr-large-pdf.html hoping that once we get over this tough moment, it would be useful for others. Of course, since it's a JasperReports related issue, I believe the best place to discuss alternatives is this list. Cheers Javier By: Alex Parfenov - aparfeno RE: Strategies for large reports 2003-03-24 12:02 This is little bit of a longer shot, but on the same subject: Teador, In the future versions of JR, do you think that it would make sense to modify JR to allow streaming (or continous-process) report generation instead of batch-process. What I mean is, instead of building a large JRPrint object and filling it later, can JR 'stream' JRPages to the JRPrinter and JRPrinter, in turn, generates desired output (PDF, XLS, etc.), all as one continous process. I realize this isn't a simple change, but it would definitly address the scalability problems and in extreme cases will also greately improve performance. With this change the data from the database would be piped 'through' JRFiller and JRPrinter and out to the file system or http, instead of being accumulated in memory as one monsterous JRPrint object. Alex By: Teodor Danciu - teodord RE: Strategies for large reports 2003-03-25 00:48 Hi, I already have some ideas about how to do this. It is not simple, but at least it is not impossible. However, the first thing we loose if we want to stream out on-the-fly is the ability to use the "evaluationTime" feature. This means that we won't be able to display on the first page the total number of pages, because with this approach we cannot go back and display values that are calculated only later in the report filling process. This could be acceptable for some and not acceptable for others. We could add a parameter to let the user decide what kind of report generation he/she wants. I'll put this on my TODO list and let's hope I'll find some spare time to deal with it as soon as possible. Thank you, Teodor By: Paulo Soares - psoares33 RE: Strategies for large reports 2003-03-25 03:52 There are techniques, using templates, to show in any page text that is only written at the end. By: Alex Parfenov - aparfeno RE: Strategies for large reports 2003-03-25 10:53 What about the following: Let's say you place JRPages into an ordered list as you do now. Another process releases (and removes) each page from the top of that list and passes it to JRFiller ONLY if all fields on that page have been filled-in. What's going to happen is that if the report designed such that your title page needs to wait till JR generated the rest of 10000 page report (if you have evaluationTime=Report field in the title), then all 10000 pages will be kept in memory and not released until last page has been filled. However if the author avoided such design patterns and maybe only used evaluationTime=Group (let's assume groups are much smaller in this example, say 10 pages), or evaluationTime=Page, then this 10000 page report will never require more then 10 pages-worth of memory. So the idea is instead of using an absolute parameter that disables evaluationTime fields, JR will try to adopt and allow author some flexibility.
  15. By: Jaisankar Arunachalam - jsankar parameter index out of range 2003-03-25 03:25 I'm using a query as following in one of my report. The report is perfectly working if parameter is specified outside quotes(' ') or if i specify the value directly without parameter. But I'm getting a parameter index out of range, if the parameter is specified inside quotes of the query. As per my requirement I need to specify the parameter inside quotes. Is there any solution to solve my problem? The query is : not working : select * from employmentcrosstab( 'select 1 as rowid, b.employmentduration_desc, a.person_id from injured a full outer join employmentduration b on a.employmentduration_id=b.employmentduration_id where a.event_id=$P{event_id};') working: select * from employmentcrosstab( 'select 1 as rowid, b.employmentduration_desc, a.person_id from injured a full outer join employmentduration b on a.employmentduration_id=b.employmentduration_id;') where a.rowid=$P{event_id} The error messages while filling the report (it is compiling without any problem) : Parameter index out of range. at org.postgresql.jdbc2.PreparedStatement.set(PreparedStatement.java:820) at org.postgresql.jdbc2.PreparedStatement.setInt(PreparedStatement.java:201) at dori.jasper.engine.util.JRQueryExecuter.executeQuery(JRQueryExecuter.java:278) at dori.jasper.engine.util.JRQueryExecuter.executeQuery(JRQueryExecuter.java:132) at dori.jasper.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:363) at dori.jasper.engine.fill.JRFillSubreport.run(JRFillSubreport.java:380) at java.lang.Thread.run(Thread.java:536) NESTED BY : Parameter index out of range. at org.postgresql.jdbc2.PreparedStatement.set(PreparedStatement.java:820) at org.postgresql.jdbc2.PreparedStatement.setInt(PreparedStatement.java:201) at dori.jasper.engine.util.JRQueryExecuter.executeQuery(JRQueryExecuter.java:278) at dori.jasper.engine.util.JRQueryExecuter.executeQuery(JRQueryExecuter.java:132) at dori.jasper.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:363) at dori.jasper.engine.fill.JRFillSubreport.run(JRFillSubreport.java:380) at java.lang.Thread.run(Thread.java:536) NESTED BY : dori.jasper.engine.JRException: Error executing report query : select * from employmentcrosstab( 'select 1 as rowid, b.employmentduration_desc, a.person_id from injured a full o uter join employmentduration b on a.employmentduration_id=b.employmentduration_i d where a.event_id=?;') at dori.jasper.engine.util.JRQueryExecuter.executeQuery(JRQueryExecuter.java:369) at dori.jasper.engine.util.JRQueryExecuter.executeQuery(JRQueryExecuter.java:132) at dori.jasper.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:363) at dori.jasper.engine.fill.JRFillSubreport.run(JRFillSubreport.java:380) at java.lang.Thread.run(Thread.java:536) Caused by: Parameter index out of range. at org.postgresql.jdbc2.PreparedStatement.set(PreparedStatement.java:820) at org.postgresql.jdbc2.PreparedStatement.setInt(PreparedStatement.java:201) at dori.jasper.engine.util.JRQueryExecuter.executeQuery(JRQueryExecuter.java:278) regards Jaisankar
  16. By: genri como - gcomo01 queryString 2003-03-24 11:44 HI All, It looks like if you don't provide a (or provide an empty one) queryString the report won't be generated.The idea is not to use the DB directly and pass the stuff needed through the parameters.Anybody else has experienced the same problem.? thanks Genri ! By: Teodor Danciu - teodord RE: queryString 2003-03-24 12:27 Hi, Use the "whenNoDataType" attribute to instruct the engine to generate some content eve there are no records to iterate on. But you might also consider using data source objects if you do not connect to any database. Check the "datasource" sample for details. I hope this helps. Teodor By: genri como - gcomo01 RE: queryString 2003-03-24 12:29 very helpful thanks Genri
  17. By: Zsolt Berentey - zberentey Scrambled result if t1 font not installed 2003-03-22 03:07 Hi, I have encountered a strange behavior. I use a type 1 font for creating the header of my report. It is set to be embedded into the pdf doc. If the font is installed on the system everything works OK. If however it is not (or I mistype the fontName attribute) The text goes lower and the leading is increased, etc. All in all, it gets scrambled like this: Installed font not installed X X X ---------- --X-X-X-- Does anybody have any ideas? Zsolt. By: Teodor Danciu - teodord RE: Scrambled result if t1 font not installed 2003-03-22 05:03 Hi, Having the font installed on the system is a MUST for JasperReports to be able to use it. The "fontName" attribute makes reference to an installed font. The "pdfFontName", "pdfEncoding" and "isPdfEmbedded" attributes are used only when exporting to PDF. But the layout is made based on the value of the "fontName" attribute and if that font is not installed the engine will use some default font and all the layout is wrong. I hope this helps. Teodor
  18. By: Zsolt Berentey - zberentey Could we have a minHeightToStartNewColumn? 2003-03-21 10:07 Hi Teodor, 1. Have you thought about introducing a new attribute for the Group element "minHeightToStartNewColumn". Right now group can only start a new page, but this means that there can be really ugly group breaks, where the group header is printed at the bottom of the first column, while the rest is in the second one. This should be a really useful feature. 2. Is there any chance (is it possible at all?) to have a feature like <b>,<i> in HTML? I mean to change the style inline, cause horizontal positioning is a little tricky at the moment, so if I wanted to have a bold text followed by a normal one, both in the same line.... Thanks, Zsolt. By: Zsolt Berentey - zberentey RE: Could we have a minHeightToStartNewColumn? 2003-03-21 15:22 Ok, seems that minHeightToStartNewPage works for the column brakes as well. I was a little too hasty... By: Teodor Danciu - teodord RE: Could we have a minHeightToStartNewColumn? 2003-03-22 04:53 Hi, I have the feature 2. on my mind from sometime now... It is not simple, but possible. I hope we'll have it on of the future versions. Thank you, Teodor
  19. By: duane magpali - magpali classes classes 2003-03-22 01:00 thanks for the referral of ireport guys but i need a tool that would run in linux coz i am designing our reports in that OS. some more questions though.... i need the BARE BONES XML codes in jasper reports to be able to insert images/pictures in the reports generated. i already saw the sample code in the jasperreports SF site but I am a just a beginner in XML so I need some help on it. thanks very much!
  20. By: Zsolt Berentey - zberentey supplying font in webapp for pdf 2003-03-20 11:36 I am probably a very newbie to the subject, although I have read through all the threads concerning this issue. Still, I have a problem of using non built-in fonts with PDF. I'd like to supply the fonts (both t1 and ttf) with the web-app, and wouldn't like to use absolute paths in the report file. Can someone tell me where to put the font files (the exact location realtive to the WEB-INF directory for example) and what to put into the pdffontname attribute? I am using tomcat. Thanks, Zsolt. By: Teodor Danciu - teodord RE: supplying font in webapp for pdf 2003-03-21 00:56 Hi, Put the TTF files in the Web application classpath. This means you have to put them under the WEB-IN/classes directory. If your TTF file is placed placed here: WEB-INF/classes/fonts/MyFont.TTF then in the XML you write pdfFontName="fonts/MyFont.TTF" I hope this helps. Teodor By: Zsolt Berentey - zberentey RE: supplying font in webapp for pdf 2003-03-21 09:24 Hi, Thanks for the answer. I was doing exactly this, but I used a lowercase extension while the file had an uppercase one. While the File object found it when using an absolute path (win2k), the resource loader could not :)) So, this solved the problem but raised another. Now the resource is found, but I get an exception: com.lowagie.text.DocumentException: Two byte arrays are needed if the Type1 font is embedded. at com.lowagie.text.pdf.Type1Font.(Unknown Source) at com.lowagie.text.pdf.BaseFont.createFont(Unknown Source) at dori.jasper.engine.export.JRPdfExporter.exportText(JRPdfExporter.java:1009) ... What's missing? Thanks, Zsolt. By: Zsolt Berentey - zberentey RE: supplying font in webapp for pdf 2003-03-21 11:47 Found way to patch it. Can you look at it Teodor? It should be put into dori.jasper.engine.export.JRPdfExporter:exportText() line 996 if (baseFont == null) { byte[] bytes = null; byte[] pfb = null; try { bytes = JRLoader.loadBytesFromLocation(jrFont.getPdfFontName()); if (jrFont.getPdfFontName().toLowerCase().endsWith(".afm")) { pfb = JRLoader.loadBytesFromLocation(jrFont.getPdfFontName().substring(0, jrFont.getPdfFontName().length() - 3) + "pfb"); } } catch(JRException e) { throw new JRException("Could not load font from location : " + jrFont.getPdfFontName()); } baseFont = BaseFont.createFont( jrFont.getPdfFontName(), jrFont.getPdfEncoding(), jrFont.isPdfEmbedded(), true, bytes, pfb ); } Zsolt. By: Paulo Soares - psoares33 RE: supplying font in webapp for pdf 2003-03-21 16:51 The last version of iText tries to load the font from a resource if it's not found as a file.
  21. By: Ryan Johnson - delscovich Page break problem 2002-08-16 17:04 Hi all, I have a report with two columns, and if there are enough data rows to start the second column, the report becomes two pages long, with a blank second page. I've tried everything I can think of to make sure it's not some setting (summaryNewPage="false", etc), and nothing seems to make a difference. This happens in both 3.2 and 3.3, as near as I can tell. Any ideas? Thanks, Ryan By: Teodor Danciu - teodord RE: Page break problem 2002-08-19 05:05 Hi, I think I know what the problem is. It is indeed caused by the summary section, but not by the "isSummaryNewPage" flag as you mentioned. The summary will get printed on the same page as the last row ONLY IF on this last page of the report there is only one column started and no more. Why? Because if there is more than one column started, it means that the first one has run to the bottom of the page already, and there won't be any space left for the summary section on this page. You could say that your summary section has the height equal to zero and therefore we should not start a new page just to leave it blank. But the summary height equal to zero does not mean that you cannot place zero height text fields that would stretch with overflow and get printed anyway. So, this is how the library was always working and the only solution I see is to add the "printWhenExpression" functionality at band level. This is on my to do list, but never got the chance to give it a serious thought. I'll try. Thank you, Teodor By: Zsolt Berentey - zberentey RE: Page break problem 2003-03-21 11:45 Teodor, I would like to propose a patch: As you've suggested somewhere in the forum, an ugly solution would be to check the print file for empty page. This gave me the idea to patch the isToPrint method if JRFillBand. Here it is: protected boolean isToPrint() { if (this.isPrintWhenExpressionNull() || (!this.isPrintWhenExpressionNull() && this.isPrintWhenTrue())) { if ((getHeight() == 0) && (getElements().length == 0) && (getChildren().size()==0)) return false; else return true; } else return false; } This prevents the summary to be printed when there are no elements in it AND its height is 0. Do you see any problems with this? It solved my problem of an unwanted empty page at the end of the report... Greetings, Zsolt.
  22. By: duane magpali - magpali some questions... 2003-03-21 11:06 I am using JasperEdit and Openreports for designing our reports for our thesis. However, I also want to see my report design through jasperviewer. how can i do that? i downloaded the project files of jasperreports but still can't figure it out. Also, I design reports just by using the wizard function of JasperEdit and just come up with a bare bones report. Is there anyway i can jazz up my layouts by adding text color and pictures? How do i do this? I am pretty new in this mailing list and it seems that people code here in XML through notepad. is that the only way? is there an easier one? By: juan david vergara perez - jvergara RE: some questions... 2003-03-21 11:23 user the iReport u can download it from http://sourceforge.net/projects/ireport
  23. By: genri como - gcomo01 getConnection() causes a OutOfMemoryError 2003-03-20 17:40 I have a report and a subreport.For the subreport, I am using a Map to pass as a parameter a Connection for the connectionExpression(the value of that I get through DriverManager.getConnection()).Whenever is executed,it causes a OutOfMemoryError exception.Anybody has experienced a similar situation. thanks Genri ! By: Teodor Danciu - teodord RE: getConnection() causes a OutOfMemoryError 2003-03-21 00:50 Hi, If there are many records in the datasource, use the -Xmx switch in the command line to allow the JVM to use more memory when you launch java.exe. I hope this helps. Teodor By: genri como - gcomo01 RE: getConnection() causes a OutOfMemoryError 2003-03-21 05:40 The report and the subreport work fine separately.The problem occurs whenever they are put together.The records returned are not that many (range of 10s and dealing with a small test DB).Could it be a jdbc driver problem..thanks
  24. By: Ruben Misrahi - rnmisrahi System property org.xml.sax.driver not specif 2003-02-27 06:20 I get this using JBuilder8. Any idea why? By: ernest du plessis - linksar RE: System property org.xml.sax.driver not specif 2003-03-20 01:01 Did you use System.setProperty("org.xml.sax.driver"); in your program? By: Suraj Amin - suraj_amin RE: System property org.xml.sax.driver not sp 2003-03-20 04:30 The exact cmd would be: System.setProperty("org.xml.sax.driver", "org.apache.xerces.parsers.SAXParser"); or just pass -Dorg.xml.sax.driver=org.apache.xerces.parsers.SAXParser to the java cmd -- Regards, Suraj Amin Homepage: http://www.geocities.com/suraj_amin/ /* May the source be with you */ By: Suraj Amin - suraj_amin RE: System property org.xml.sax.driver not sp 2003-03-20 04:32 Sorry forgot to mention that you would also have to add the xerces lib to your Jbuilder project. -- Regards, Suraj Amin Homepage: http://www.geocities.com/suraj_amin/ /* May the source be with you */
  25. By: ernest du plessis - linksar java webstart - how to read xml from jar 2003-03-20 01:12 I read a xml file into my java application.With the following line: JasperCompileManager.compileReportToFile("xmlfile.xml"); The problem is when the class file and xml is complied to a jar.The application can not find the xml file. Is there another way to read this xml file when it is in a jar? By: Suraj Amin - suraj_amin RE: java webstart - how to read xml from jar 2003-03-20 04:27 Hi there, You could use the following to complile: JasperReport jasperReport = JasperCompileManager.compileReport( this.getClass().getResourceAsStream("xmlfile.xml")); -- Regards, Suraj Amin Homepage: http://www.geocities.com/suraj_amin/ /* May the source be with you */
×
×
  • Create New...