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

2006 IR Open Discussion

Members
  • Posts

    776
  • 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 2006 IR Open Discussion

  1. By: oturan_ - oturan_ Using List, ArrayList, Vector as datatype(s) 2006-04-17 04:00 I have questions here using iReport (version greater or equal to 1.1.0) : 1.) On the version(s) of iReport, can I use List, ArrayList or Vector as a datatype of my parameter? 2.) And if ever these datatypes could be used, how can I access them in textfields, or how can it be used in variables (such as list.get(0), or use an iterator to get the details of the list) ? I preferably need to use any of these datatype(s), if ever the any of the available version(s) supports it, in the project I am currently working into. Thanks in advance and good day.
  2. By: ka4sri_1999 - ka4sri_1999 pie chart 2006-04-17 01:09 Hi, I need help with a pie chart developmennt from a XML datasource. For example if my xml is: <CreditUtilization> <A>2500</A> <B>3500</B> </CreditUtilization> I need help in drawing a pie chart between A and B. Please help. Thanks & Regards Subashree
  3. By: snipex - snipex handling jasperreports and IReport 2006-04-14 07:16 Hi, can anyone help? i am using jasperreports with IReport designer to design and generate my reports. i have a collection of objects and i want to have them listed in my report. 1) how do handle the jasperreports java class 2) how do i design my IReport xml file. 3)how do i go about datasource setting in IReport thanks
  4. By: Jonathan - jonathan0000000 Subreport data spacing problems 2006-04-12 09:24 I have a complex report that contains many subreports. Sometimes data from later subreports gets printed before earlier subreports. This only happens when the later subreport detail is shorter than the earlier subreport detail. Example report design: ------------------------------------------------ "PAGE "+$V{PAGE_NUMBER} ...some stuff that fills most of the page... Subreport A Subreport B ------------------------------------------------ If there is not enough space on the page to print an item from subreport A, I want the report to print like this: ------------------------------------------------ PAGE 1 ...some stuff that fills most of the page... PAGE 2 detail A1 detail A2 detail B1 detail B2 detail B3 ------------------------------------------------ But if the detail items in subreport B are smaller than those in subreport A, it sometimes prints like this: ------------------------------------------------ PAGE 1 ...some stuff that fills most of the page... detail B1 PAGE 2 detail A1 detail A2 detail B2 detail B3 ------------------------------------------------ The only way I have found to stop this behavior is to put a large space between subreports A and B, but then I always have this big empty space in the middle of the report. Is there any other way to solve this problem?
  5. By: Hendry - hendrykho Application Identifier field in barcode tool 2006-04-12 05:17 Hi all, What is application identifier for? I found it in barcode tool and I couldn't leave it as empty field as when I run it it become null but I put as Empty String it's still not working. I am using ireport 1.2.1 Is it a bug? Thanks Hendry
  6. By: venkat - venkat1201 Multiple SubReport's 2006-04-11 20:56 Hello Everybody, I am having problem while i am using two subreports vertically(one by one).Because while i am running these two have to be in the details part of the report these two while have many records which will be dinamically changed for different inputs can u please tell me is there any way to solve this situation. regards venkat
  7. By: Alan O'Leary - aloleary Simple Time Series Chart - Purchased Manual 2006-04-11 04:25 Hello, I just purchased the manual thinking the chart section would show me what to do but it only goes over very basic pie charting. This is very disappointing as this information is available on the web already for free... Anyways what I'm looking for is a walk through of creating a time series chart as I am getting something wrong with the "series". The time series and values are perfect but dont know what/how to configure the series to get the data displayed correctly... Any help appreciated.. -A
  8. By: Percibal - percibalinux Make iReport DISPOSE_ON_CLOSE 2006-03-27 07:18 How can I make the iReport Window to close but not end the program in a Java Application? By: venkat - venkat1201 RE: Make iReport DISPOSE_ON_CLOSE 2006-03-27 20:17 hi, Just open the iReport viewer to be open in a new window that mean new Frame i think this may solve u'r problem regards venkat By: Percibal - percibalinux RE: Make iReport DISPOSE_ON_CLOSE 2006-03-28 04:28 Hi, thanks for your reply. I'm trying different ways to do this, for example: JasperViewer viewer = new JasperViewer(jasperPrint, true); viewer.setDefaultCloseOperation(viewer.HIDE_ON_CLOSE); viewer.setVisible(true); But it still ending the program when I close the iReport Window. What do you think? regars Percibal. By: venkat - venkat1201 RE: Make iReport DISPOSE_ON_CLOSE 2006-03-28 04:43 there u r making a small mistake just add the viewer to the new frame ok. if u want help in coding ask me i will send u all the code how to do it its too simple regards venkat By: venkat - venkat1201 CODE FOR JASPERVIEWER CLOSING 2006-03-28 21:32 Frame frame = new Frame(); frame.setSize(700,700); frame.add(viewer); //viewer is the object of jasperviewer //JasperViewer viewer = new JasperViewer(jasperPrint, true); and add windows listner to close this frame By: Percibal - percibalinux RE: Make iReport DISPOSE_ON_CLOSE 2006-03-30 05:15 Thanks very much, now it is working, also I have to use AddContainer becouse this code return and "adding Window to a container" error. Again, thank for your help!!! regards Percibal. By: venkat - venkat1201 U can DO it like this also 2006-03-30 23:28 final javax.swing.JDialog viewerwindow = new javax.swing.JDialog(new JFrame(), "Report Viewer ", true); viewerwindow .getContentPane().add(Jasperviwerobject); viewerwindow .setBounds(new Rectangle(500, 300)); viewerwindow .addWindowListener(new WindowAdapter() { public void windowClosing(WindowEvent winevt) { viewerwindow .dispose(); } }); viewerwindow .setVisible(true); By: goodpp - goodpp RE: Make iReport DISPOSE_ON_CLOSE 2006-04-07 18:14 WindowListener[] wl = jView.getWindowListeners(); for(int i=0; i<wl.length; i++) { jView.removeWindowListener(wl); } jView.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE); jView.setVisible(true);
  9. By: carole - wy_carole if subreport must use connection ? 2006-04-06 00:18 my master report run ok!but it can not found the subreport,why?If subreport must use connection or datasource?The data I want to show is need not to get from database,what can I do?Help me!Thanks very much!
  10. By: pcatower - pcatower Display problem for chinese characters in CSV 2006-04-05 19:35 HI, I have problem in displaying traditional chinese characters when generating the CSV file. Following is the Font properties I have selected for the field: - Font name: MingLiU_HKSCS (tried also MingLiU) - PDF font name: MHei_Medium All the chinese characters become "?" on the result file... but it works fine for PDF and Excel format. Thx for all the ways u help.
  11. By: pcatower - pcatower Display problem for chinese characters in CSV 2006-04-05 19:35 HI, I have problem in displaying traditional chinese characters when generating the CSV file. Following is the Font properties I have selected for the field: - Font name: MingLiU_HKSCS (tried also MnigLiU) - PDF font name: MHei_Medium All the chinese characters become "?" on the result file... but it works fine for PDF and Excel format. Thx for all the ways u help.
  12. By: carole - wy_carole How use the fields which type is List? 2006-04-05 18:28 Hi: Formerly,I only use iReport easyly,so I don't know it very much.The type of Fields in iReport usually is String ,Integer or float,but now I want to use List,Could you tell me how to do ?Thanks! Please forgive my poor English!I don't know if you understand what I mean! By: carole - wy_carole RE: How use the fields which type is List? 2006-04-05 18:35 And there are VO in the List,some fields which type is String or Integer are in that VO.How can I do?Please help me!Thank you very much!
  13. By: C-Box - c-box Element DoubleClick PropertiesDialog vs. edit 2006-04-05 05:12 Hi all, I just got the newest version from CVS and recognized that when I doubleclick on an element the properties-dialog doesn't appear anymore... instead you can directly edit the textfield/static-text .... In my opinion it's good for some user and not so good for other ones... What about a new option "Edit on doubleclick" where the user can decide whether he want's to edit directly or if he get the properties-dialog shown. What do you think about it??? C-Box
  14. By: juanp - qbsoft vertical orientation codabar? 2006-04-04 05:44 How can I put a codabar in vertical orientation?
  15. By: Fek - fekmfg Charts problem 2006-04-04 01:48 Hi, I have an error when try to compile my report when I have inserted an chart. I recieve the following message: ERROR digester.Digester - Parse Error at line 114 column 17: The content of element type "dataset" must match "EMPTY". org.xml.sax.SAXParseException: The content of element type "dataset" must match "EMPTY". Why ? I have defined an XYseries in the ChartData /Details dialog. Greeting Fek
  16. By: venkat - venkat1201 How to get row number 2006-03-23 04:27 How to get row number auto increment for each row By: Rapsodia - rapsodia RE: How to get row number 2006-03-30 00:08 To get row number you have 2 variables: COLUMN_COUNT return the row number, but it reset foe each page REPORT_COUNT return the row number, indipendently of the page. I hope to have help yuo
  17. By: Carl.Li - carl_li Page X of Y 2005-09-14 03:29 It's the first time for me to use iReport. How to add "Page X of Y" to the page footer of the report? Thanks! By: sangar_g - sangar_g RE: Page X of Y 2005-09-16 05:11 Hi carl, Use the variable PAGE_NUMBER (data type : Integer ) in both X & Y positions. For X, choose the evaluation time as 'Now' and For Y, choose the evaluation time as 'Report' thats all. Regs, Sangar_G. By: pubDispName - mellino RE: Page X of Y 2005-11-04 08:41 And how to put the total pages number in a variable? and pass it to a subreport? By: Remo Fritzsche - remofritzsche RE: Page X of Y 2006-02-16 06:34 yes, i've the same problem. i want to make an expression as follows: new Boolean($V{CURRENT_PAGE_NUMBER} != 1) (print a specific band only if the number of the current page not equals 1) but this example won't run. By: Giulio Toffoli - gt78 RE: Page X of Y 2006-02-20 10:03 Question 1: And how to put the total pages number in a variable? You can't. The total pages number is the value of the builtin variable PAGE_COUNT. You can print using a textfield with evaluation time = report. Question 2: and pass it to a subreport? If you don't have yet reached the end of the report is no possible to know the number of pages that will be generated. Anyway you have access only to the current page number. Question 3: print a specific band only if the number of the current page not equals 1 new Boolean($V{CURRENT_PAGE_NUMBER} != null && $V{CURRENT_PAGE_NUMBER}.intValue() > 1) Giulio By: David Ender - degc RE: Page X of Y 2006-03-27 08:43 Hi, I want to use the same page header/footer for all of my reports. This makes the change management more efficient. So what I did was to create two subreports (one as page header and one as footer) and every report has as its header/footer these subreports. What I have learned so far, "page X of Y" wont work if it is located in the subreport of page footer. - What would be the work around? Post edited by: tcloonan, at: 2006/09/02 10:31
  18. By: Welkin Hu - welkinhu Simple way support customized query language 2006-03-05 23:16 I want to support customized query language, which need simple iReport enhancement. I developed a general JRDataSourceProvider class for all report. In general class's getFields(JasperReport) method, I parsed the query string and return all fields' definition. But now, iReport can not pass JasperReport in getFields Method. In fact, I use HQL as my query language. iReport 1.2.0 already support it. But it directly use hibernate.cfg.xml. I have some specical data operations in my data source provider. So what I want is call my general data souce provider. How about pass JasperReport in getFields() if I complied the report in iReport? By: Giulio Toffoli - gt78 RE: Simple way support customized query langu 2006-03-06 09:40 I'll support this in the next ireport version Giulio By: Welkin Hu - welkinhu RE: Simple way support customized query language 2006-03-23 23:08 Send JasperReport in getFields is not always available. The better choise is sent JasperDesigner object.
  19. By: Peter VanCaeseele - peter_vc CVS checkout problems 2006-03-20 06:11 Is anyone else having problems checking out or updating from the CVS? I've been trying for days and I'm having no luck. Is the new SVN service available yet? By: venkat - venkat1201 RE: CVS checkout problems 2006-03-23 20:27 can u tell me what the exact problem is and with which integrated tooll u'r using it . r else r u using "tortoise cvs". by that i will try to help u. venkat
  20. By: ngy - ngy not work in jdk1.5.0_06 2006-03-21 17:57 Even the latest version of iReport-1.2.0 also cannot start with jdk1.5.0_06. Seems the iReport-1.2.0 not has used some AWT function that has been obsoluted in the jdk1.5. By: Giulio Toffoli - gt78 RE: not work in jdk1.5.0_06 2006-03-23 11:14 I develop and use iReport with java 1.5. What's your problem? Giulio
  21. By: Bruce Martin - bruce_a_martin RE: Datasource for Fixed field width files 2006-03-17 04:17 If anyone is interested, I have added a Jasper DatasourceProvider for Fixed Width Data files (i.e. Cobol) to the RecordEditor project http://record-editor.sourceforge.net/ . It can handle both Text and binary files. For details see http://record-editor.sourceforge.net/re2Jasper.htm . Note this is still very much an example program and needs more testing. By: Giulio Toffoli - gt78 RE: Datasource for Fixed field width files 2006-03-20 01:38 Wow, very cool tutorial! Giulio
  22. By: cyclistca - cyclistca Problems with the Expression Editor 2006-03-17 09:48 If I bring up the expression editor then switch to another application on my desktop iReports locks up. I then have to close and reopen the application. Is this a know issue? Are there any plans to fix this? By: Giulio Toffoli - gt78 RE: Problems with the Expression Editor 2006-03-20 01:32 Simply the expression editor disappear behind the main window. CTL+TAB to bring the back the widow to front. I have to set a parent window for the Expression Editor. I'll fix soon. Giulio
  23. By: cyclistca - cyclistca Debug Tools in iReports 2006-03-06 16:29 Are there any plans to introduce debugging tools into iReports? Two that I can think of that would be helpful 1. Variable watch 2. The ability to set break points. I find especially when you have a run time error that it is hard to narrow down in which component the error is occurring. By: Giulio Toffoli - gt78 RE: Debug Tools in iReports 2006-03-08 15:21 I'm thinking about. Anyway the kind of debug you need can be done with a scriptlet. Giulio By: cyclistca - cyclistca RE: Debug Tools in iReports 2006-03-17 09:50 It's not apparent to me how this would be done. Do you have any suggestions?
  24. By: iridaus - iride-75 Problem with Crosstab 2006-03-13 04:36 I have produced a report with CrossTab, but when I run this, appears this error: Compiling to file... D:irideDocumentazione Prodotti Open Source BIiReportReport 06_03_2006Report Compilaticlassic.jasper -> D:Programmi Open sourceiReport-1.2.0classic.java it.businesslogic.ireport.ReportClassLoader@19fa905 Compilation running time : 204 Filling report... Locale: italiano (Italia) Error filling print... net.sf.jasperreports.engine.JRException: Crosstab data has already been processed. at net.sf.jasperreports.crosstabs.fill.calculation.BucketingService.addData(BucketingService.java:280) at net.sf.jasperreports.engine.fill.JRFillCrosstab$JRFillCrosstabDataset.customIncrement(JRFillCrosstab.java:634) at net.sf.jasperreports.engine.fill.JRFillElementDataset.increment(JRFillElementDataset.java:134) at net.sf.jasperreports.engine.fill.JRCalculator.calculateVariables(JRCalculator.java:154) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:621) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportContent(JRVerticalFiller.java:248) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:132) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:730) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:632) at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:63) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:402) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:234) at it.businesslogic.ireport.IReportCompiler.run(IReportCompiler.java:674) at java.lang.Thread.run(Unknown Source) NESTED BY : net.sf.jasperreports.engine.JRException: Crosstab data has already been processed. at net.sf.jasperreports.crosstabs.fill.calculation.BucketingService.addData(BucketingService.java:280) at net.sf.jasperreports.engine.fill.JRFillCrosstab$JRFillCrosstabDataset.customIncrement(JRFillCrosstab.java:634) at net.sf.jasperreports.engine.fill.JRFillElementDataset.increment(JRFillElementDataset.java:134) at net.sf.jasperreports.engine.fill.JRCalculator.calculateVariables(JRCalculator.java:154) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:621) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportContent(JRVerticalFiller.java:248) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:132) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:730) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:632) at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:63) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:402) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:234) at it.businesslogic.ireport.IReportCompiler.run(IReportCompiler.java:674) at java.lang.Thread.run(Unknown Source) NESTED BY : net.sf.jasperreports.engine.JRRuntimeException: Error incrementing crosstab dataset at net.sf.jasperreports.engine.fill.JRFillCrosstab$JRFillCrosstabDataset.customIncrement(JRFillCrosstab.java:638) at net.sf.jasperreports.engine.fill.JRFillElementDataset.increment(JRFillElementDataset.java:134) at net.sf.jasperreports.engine.fill.JRCalculator.calculateVariables(JRCalculator.java:154) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:621) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportContent(JRVerticalFiller.java:248) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:132) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:730) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:632) at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:63) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:402) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:234) at it.businesslogic.ireport.IReportCompiler.run(IReportCompiler.java:674) at java.lang.Thread.run(Unknown Source) Caused by: net.sf.jasperreports.engine.JRException: Crosstab data has already been processed. at net.sf.jasperreports.crosstabs.fill.calculation.BucketingService.addData(BucketingService.java:280) at net.sf.jasperreports.engine.fill.JRFillCrosstab$JRFillCrosstabDataset.customIncrement(JRFillCrosstab.java:634) ... 12 more Print not filled. Try to use an EmptyDataSource...! Thanks, Iridaus
  25. By: Kostas Michailidis - mkostas_gr Dynamic subreport 2005-10-10 03:40 I have a report which shows 200 product codes with their short description. Inside the JasperViewer, the user wants to click on a product code to see product details. The problem is that I do not know in adnavce which product will be clicked. Also, using Hyperlink reference, I can reference only existing reports. Does anybody have an idea, how to do it? By: toloverme - toloverme RE: Dynamic subreport 2005-10-19 20:40 look By: Kostas Michailidis - mkostas_gr RE: Dynamic subreport 2005-10-11 06:07 This can be done! I wrote my HyperlinkListener and added it to the JRViewer list of Hyperlink listeners. The subreport layout and datasource name and some parameters must be specified in iReport's Hyperlink Reference Expression using some convetion f.e "!subreport.jasper,mySubreportDataSource,param1,param2". Inside my HyperlinkReferenceListener class I create the new subreport dynamicly calling JasperFillManager.fillReport(). The JasperPrint object is then shown in separate JasperViewer. User can drill-down clickink on the hyperlinks. Please comment and let's see another ways. By: anuseb - anuseb RE: Dynamic subreport 2006-03-07 01:26 can u be more elaborate please..? i want to implement the same situation. What is this HyperlinkListner class...Is it a user defined class...if so where should write it.. Can u share the code with me..? By: anuseb - anuseb RE: Dynamic subreport 2006-03-07 01:45 any one pls help...how can i drill down by clicking on the hyperlinks and creating dynamic subreports...? By: Kostas Michailidis - mkostas_gr RE: Dynamic subreport 2006-03-07 02:11 Please, look into the latest version of the iReport and JasterReports for this. If there is no such feature implemented, send me your e-mail address to michailidis@amasa.gr in order to help you. Kostas By: Kostas Michailidis - mkostas_gr RE: Dynamic subreport 2006-03-10 08:28 Hallo Anu, as I informed you by e-mail, I can refer only to the implementation with the JasperViewer. I have no idea how to do it with PDF files. The user click on parent report's hyperlink element is handled in the JRViewer class which is part of Jasper Reports library. So, create a new class f.e Viewer99 by subclassing JRViewer and add "your" hyperlink listener, like this Code: public class Viewer99 extends JRViewer { public Viewer99(JasperPrint jrPrint) { super(jrPrint); addHyperlinkListener(new HyperLinkReferenceListener()); } public Viewer99(String fileName, boolean isXML) throws JRException { super(fileName, isXML); } public Viewer99(InputStream is, boolean isXML) throws JRException { super(is, isXML); } } HyperLinkReferenceListener class implements JRHyperlinkListener and could be like this public class HyperLinkReferenceListener implements JRHyperlinkListener { public void gotoHyperlink(JRPrintHyperlink hyperlink) { int idx, idx2, i; DBASource jrData = null; if (hyperlink.getHyperlinkType() == JRHyperlink.HYPERLINK_TYPE_REFERENCE) { //System.out.println(hyperlink.getHyperlinkReference()); String hyperlink_reference_exp = hyperlink.getHyperlinkReference(); if (hyperlink_reference_exp.startsWith("!"«»)){ idx = hyperlink_reference_exp.indexOf(','); if (idx == -1) return; //get jasper file name from hyperlink_reference_exp String jasperReportFile = hyperlink_reference_exp.substring(1,idx); //get JRDataSource class name idx2 = hyperlink_reference_exp.indexOf(',', idx+1); if (idx2 == -1) return; String dataSourceClass = hyperlink_reference_exp.substring(idx+1,idx2); //load data source class try { //THIS IS FUNDAMENTAL!!! DataSource must be of DBASource type. //Because parameters can not be passed into the class constructor, //the DBASource implements setParams mathod. //Because of the previous there must be a method for connecting //the database and creating the Resultset - openResultSet method. //Of course, the OpenResultSet method is called after calling the //setParams method, because some parametrs can participate in the //data retrieve SQL statement. //HyperlinkReference Expression format: //!report.jasper,MyDataSource,param1,param2,param3,... // // where MyDataSource is DBASource subclass // report.jasper is compiled jasper report layout // params are Strings passed into Data Source where they // are addressed by PARAM1,PARAM2,... names // jrData = (DBASource) Class.forName(dataSourceClass).newInstance(); }catch (ClassNotFoundException e) { e.printStackTrace(); }catch (InstantiationException e1) { e1.printStackTrace(); }catch (IllegalAccessException e2) { e2.printStackTrace(); } if (jrData == null) return; //get parameters i = 0; HashMap hm = new HashMap(); while ((idx = hyperlink_reference_exp.indexOf(',', idx2+1)) != -1) { hm.put("PARAM" + (++i), hyperlink_reference_exp.substring(idx2+1,idx)); idx2 = idx; } //get the last parameter hm.put("PARAM" + (++i), hyperlink_reference_exp.substring(idx2+1)); //hm.put("PARAM1", "980-0101-2001"«»); //hm.put("PARAM2","0527001"«»); jrData.setParams(hm); jrData.openResultSet(); try{ JasperPrint jrPrint = JasperFillManager.fillReport(jasperReportFile, null, jrData); jrData.closeAll(); jrData = null; JasperViewerE cl = new JasperViewerE(jrPrint); cl.setVisible(true); }catch(JRException e) { e.printStackTrace(); } }//if }//if }//public void gotoHyperlink Now the Viewer99 has the ability to catch the user's click on a hyperlink and invoke the related subreport. Viewer99 must be called inside the JasperViewer. But instead of modifying the original JasperViewer, craete a new class JasperViewerE base on it and replace any occurrence of JRViewer by Viewer99 and use JasperViewerE everywhere you need this feature. In this implementation, the subreport data source is always class implementing JRDataSource. You could find some other solution suitable for your needs. I hope this can help you. Kostas Post edited by: tcloonan, at: 2007/12/19 11:38
×
×
  • Create New...