bellakhalAmir / xdocreport

Automatically exported from code.google.com/p/xdocreport
0 stars 0 forks source link

Android - Impossible to create report for the input stream #351

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Hi!
I have a problem when modify template on android. This is a error:  Impossible 
to create report for the input stream. The report loader supports only [] files 
type. 
And this is the code:

 String file=appContext.getApplicationContext().getExternalFilesDir("inventario.docx").getAbsolutePath();
        InputStream inputStream =new FileInputStream(file);

        IXDocReport report = XDocReportRegistry.getRegistry().loadReport(inputStream,
                TemplateEngineKind.Velocity);

Any idea to resolve my problem? Thanks!!

Original issue reported on code.google.com by pablo1...@gmail.com on 14 Jan 2014 at 10:53

GoogleCodeExporter commented 8 years ago
It misses fr.opensagres.xdocreport.document.docx JAR. Please use teh same JARs 
that you can download in samples or use maven dependency 
https://code.google.com/p/xdocreport/wiki/XDocReport103

Original comment by angelo.z...@gmail.com on 14 Jan 2014 at 11:12

GoogleCodeExporter commented 8 years ago
I'm trying to import lib with maven and import JAR directly, but the error 
remains.
May be another problem? Thanks

Original comment by pablo1...@gmail.com on 14 Jan 2014 at 11:21

GoogleCodeExporter commented 8 years ago
Your error means that you have not registered document kind 
(fr.opensagres.xdocreport.document.docx  doesn't load docx file type document).

The document kind is loaded with SPI Provider 
https://code.google.com/p/xdocreport/source/browse/document/fr.opensagres.xdocre
port.document.docx/src/main/resources/META-INF/services/fr.opensagres.xdocreport
.document.discovery.IXDocReportFactoryDiscovery 

I have never used XDocReport with Android, but if you tell me that 
fr.opensagres.xdocreport.document.docx JAR is in your classpath, it means that 
Android cannot manage SPI Provider?

Original comment by angelo.z...@gmail.com on 15 Jan 2014 at 5:05

GoogleCodeExporter commented 8 years ago
None answer. I close this issue.

Original comment by angelo.z...@gmail.com on 7 Aug 2014 at 5:53

GoogleCodeExporter commented 8 years ago
so xdocreport does not work in android?

Original comment by g.dilemb...@gmail.com on 23 Sep 2014 at 3:39

GoogleCodeExporter commented 8 years ago
Never tested, I don't know Android, if you can try it and give us feedback, it 
should be very cool.

Thank's!

Original comment by angelo.z...@gmail.com on 23 Sep 2014 at 3:57

GoogleCodeExporter commented 8 years ago
cleanup

Original comment by pascal.leclercq on 10 Oct 2014 at 7:37