Skip to Content

When running a standalone java program, export to pdf hangs, how can I troubleshoot

Apr 20 at 03:27 AM


avatar image
Former Member

I have a Windows 2008 R2 server on which CRystal Reports 2008 is alreday installed. I can go in designer and can run a crystal report and export to a pdf file.

I, however, want to do it from a standalone java program.

When running java program I can trace that I successfully opened the report and report has made database connection, but then my program gets hung at BytesArrayInputStream line.... I have no clue how can troubleshoot the problem. Any pointers will be helpful. I am attaching the java file as well as the .bat file used.testexportbat.txtreportexportjava.txt

System.out.println("before bytestream");

ByteArrayInputStream bais = (ByteArrayInputStream) clientDoc.getPrintOutputController().export(ReportExportFormat.PDF);

int size = bais.available(); System.out.println("size = " + size);

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

0 Answers