Results 1 to 3 of 3
  1. #1
    narancic is offline Member
    Join Date
    Nov 2010
    Posts
    1
    Rep Power
    0

    Exclamation Jasper iReport - export report to DOCX from Java servlet (problem)

    Hi,



    I tried to generate report in DOCX format from Java servlet, using Jasper iReport and the next code:

    JRDocXExporter exporter = new JRDocxExporter();
    exporter.setParameter(JRDocxExporterParameter.OUTP UT_FILE, new File(outFileName));
    exporter.setParameter(JRExporterParameter.JASPER_P RINT, print);
    exporter.exportReport();

    I am using Jasper iReport 3.7.3 and JBoss 5.0 server. Datasource for the report is a XML file.

    In the last line (call exportReport()), JBoss generates this exception:

    Caused by: java.net.URISyntaxException: Illegal character in path at index 115: vfszip:/D:/jboss-5.1.0.GA/server/default/lib/jasperreports-3.7.3.jar/net/sf/jasperreports/engine/export/ooxml/docx/[Content_Types].xml
    at java.net.URI$Parser.fail(URI.java:2809)
    at java.net.URI$Parser.checkChars(URI.java:2982)
    at java.net.URI$Parser.parseHierarchical(URI.java:306 6)
    at java.net.URI$Parser.parse(URI.java:3014)
    at java.net.URI.<init>(URI.java:578)
    at org.jboss.virtual.VFSUtils.toURI(VFSUtils.java:505 )
    at org.jboss.virtual.plugins.registry.DefaultVFSRegis try.getFile(DefaultVFSRegistry.java:140) ... 34 more



    Generate PDF report is OK (without errors). Generate DOCX report directly from iReport is OK too.

    I've tried to generate the report from standalone Java application and it's OK, but from servlet error happens.

    Maybe, the problem is in some JBoss libraries - maybe there are some conflicts....

    Also, the file in exception ([Content_Types].xml) consists invalid url as xml schema, but this file is in all jar archives which Jasper is using.



    Does anyone have the same problem or any comments and/or suggestions?



    Thanks,

    Dragan

  2. #2
    johant is offline Member
    Join Date
    Mar 2012
    Posts
    2
    Rep Power
    0

    Default Re: Jasper iReport - export report to DOCX from Java servlet (problem)

    Hi Dragan,

    I wonder If you already solved this issue. I'm having this same trouble on jasperreports-3.7.4.jar and JBoss 5.1.0 server.
    Thanks in advance.

    Johan
    Last edited by johant; 03-10-2012 at 12:13 AM.

  3. #3
    johant is offline Member
    Join Date
    Mar 2012
    Posts
    2
    Rep Power
    0

    Default Re: Jasper iReport - export report to DOCX from Java servlet (problem)

    Seems that there is a concluding answer on this forum
    JasperForge > JasperReports Library Forums

Similar Threads

  1. jasper report problem
    By realosso in forum New To Java
    Replies: 3
    Last Post: 06-22-2010, 12:51 PM
  2. jasper report ,jasper report jar files and maven dependencies.
    By rajuchacha007 in forum Advanced Java
    Replies: 1
    Last Post: 04-09-2010, 09:15 AM
  3. Problem With Dimension of Jasper Report
    By Prashant.surwade in forum Advanced Java
    Replies: 3
    Last Post: 09-19-2009, 03:29 PM
  4. Problem in running jasper report in servlet
    By khadaree in forum Java Servlet
    Replies: 1
    Last Post: 07-16-2009, 10:35 AM
  5. Jasper Report + iReport + NetBeans 4
    By Ed in forum NetBeans
    Replies: 2
    Last Post: 07-02-2007, 08:39 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •