Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Generate byte stream of ReportDocument without save()
myklynysh
Hi,
does have anyone on idea, how I can retrieve InputStream from ReportDesignHandle. now I found only the method to store ReportDesignHandle on the disc and read it again.
reportHandle.saveAs("C:/test.rpt-document");
reportHandle.close();
Is there an other way to get the Stream without storing?
Thanks in advance.
myklynysh
Find more posts tagged with
Comments
Virgil Dodson
From the IRunTask, there is a run() method. That method will take a String as output file name... but will also take a IDocArchiveWriter that you can implement to write to an outputstream. I haven't actually tried this myself but believe that is the approach to investigate... Otherwise, you can write the rptdocument to the file system in a tmp location and then read it back in.<br />
<br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
IRunTask task = engine.createRunTask(design);
...
task.run("output/test.rptdocument");
</pre>