Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

How to generate PDF report directly instead of RPT report by using JRC ?


Good Day !

How to generate PDF report directly instead of RPT report by using Crystal Reports XI Release 2 Java Reporting Component (JRC) in desktop (Swing thick-client) ?

My GUI program will generate a RPT report, then i can export to PDF file, this is ok, no problem.


i want it direct to generate a PDF report, not a RPT report.

The code like below (2 java files)



ReportClientDocument reportClientDoc = new ReportClientDocument();, 0);

ParameterFieldController paramFieldController = reportClientDoc.getDataDefController().getParameterFieldController();

paramFieldController.setCurrentValue("", "XXX", DomainClass.getXXX());

new ReportViewerFrame(reportClientDoc);



// End of

// Begin

public class ReportViewerFrame extends JFrame



//Initial window frame properties.

private final int XPOS = 80;

private final int YPOS = 60;

private final int WIDTH = 760;

private final int HEIGHT = 550;

private ReportViewerBean reportViewer = new ReportViewerBean();

private ReportClientDocument reportClientDoc = new ReportClientDocument();

public ReportViewerFrame(ReportClientDocument reportClientDoc) throws Exception


//Initialize frame properties.


this.setLocation(XPOS, YPOS);

this.setSize(WIDTH, HEIGHT);

this.setTitle("Crystal Report Java Viewer");

//Add GUI components to the frame including the ReportViewerBean.


//Add GUI listeners to the frame.


//Set the report that the ReportViewerBean will display.

this.reportClientDoc = reportClientDoc;




//Display the frame.



How to set the export option to PDF base on existing code ?

Where can i download this package/jar ?


Former Member
Not what you were looking for? View more on this topic or Ask a question