![](http://content.invisioncic.com/i328763/set_resources_3/84c1e40ea0e759e3f1505eb1788ddf3c_pattern.png)
tanguy.yves
-
Posts
5 -
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
Posts posted by tanguy.yves
-
-
Hello,
I am running iReport 5.6.0 and a very simple report (one title and 1 line in band detail). Compilation as well as preview is running well.
Now I try to do the same with Eclipse Oxygen (JRE 1.7) and I am facing the two following issues :
1 - no jasper file produced
2- my final report (pdf or html) doesn't contain the expected content (simple title and band detail), seem to be empty
My java code is hereafter :
import java.io.FileInputStream;
import java.io.InputStream;
import java.util.HashMap;
import net.sf.jasperreports.engine.JasperCompileManager;
import net.sf.jasperreports.engine.JasperExportManager;
import net.sf.jasperreports.engine.JasperFillManager;
import net.sf.jasperreports.engine.JasperPrint;
import net.sf.jasperreports.engine.JasperReport;
import net.sf.jasperreports.engine.data.JRMapArrayDataSource;
import net.sf.jasperreports.engine.design.JasperDesign;
import net.sf.jasperreports.engine.export.ooxml.JRXlsxExporter;
import net.sf.jasperreports.engine.xml.JRXmlLoader;
import net.sf.jasperreports.export.SimpleExporterInput;
import net.sf.jasperreports.export.SimpleOutputStreamExporterOutput;
import net.sf.jasperreports.export.SimpleXlsxReportConfiguration;
public class Main {
public static void main(String[] args) {
try {
// I don't use data for my simple report so I think null for dataSource is not blocking point
JRMapArrayDataSource dataSource = new JRMapArrayDataSource(null);
HashMap<String,Object> params = new HashMap<String,Object>();
String inputsDirectory = "C:\Users\ytanguy\ireport\inputs\";
String outputsDirectory = "C:\Users\ytanguy\ireport\outputs\";
String XMLfile = "test.jrxml" ;
String PDFfile = "test.pdf" ;
String HTMLfile = "test.html" ;
JasperDesign jasperDesign = JRXmlLoader.load (new FileInputStream(new File( inputsDirectory + XMLfile)));
JasperReport jasperReport = JasperCompileManager.compileReport( jasperDesign );
JasperPrint jasperPrint = JasperFillManager.fillReport(jasperReport, params, dataSource);
//Write the report to PDF file
JasperExportManager.exportReportToPdfFile(jasperPrint, outputsDirectory + PDFfile);
//Write the report to HTML file
JasperExportManager.exportReportToHtmlFile(jasperPrint, outputsDirectory + HTMLfile);
} catch (Exception e) {
System.out.println( "Oups une exception ! "); e.printStackTrace();
}
System.out.println("Fin");
}//public static void main
}//public class
Thanks in advance for your suggestion.
Best regards
-
Hello ,
I am facing this issue as well and so far no solution found even with migration from iReport 5.0.1 to 5.1.0 release.
In addition recurrent problems are still there with 5.1.0 : docx document is seen like a set of pages made of tables
that is probably the reason of bad printing.
Thus has someone already been able to export and generate a real docx document ?
Best regards, Yves.
-
Hello,
I opened the post on August 6,2013 and the only solution I found is the one exactly described in the former answer
ie force the use of OpenJDK 7.
Best regards, Yves.
-
Hello,
I am using ireport 5.0.1 with ubuntu 12.04 LTS.
After opening a jrxml file I select Preview (with precompilation button result is the same) a windows is opened containing "i message and null" is opened and the pc is blocked (only way is to turn off/on power).
Did you already experience such issue ?
thanks in advance for your answer.
Best regards, Yves
iReport 5.6.0 hanging issue
in Products
Posted
Hi Harish,
I got the same problem and solved it with jdkhome="C:Program FilesJavajdk1.7.0_79jre" in ireport.conf file
Hope It helps you