Skip to Content
author's profile photo Former Member
Former Member

Looking for CRconfig.xml

Post Author: something_stupid

CA Forum: JAVA


I wrote a small program that should start the embedded reportviewer and show a report. When I run the program the line"D:
JRCViewReport.rpt", 0);

throws an exception: CRConfig.xml Konfigurationsdatei nicht gefunden---- Error code:-2147467259 Error code name:failed

Apparently the CRconfig.xml file cannot be found.

Question1: Can I tell the class ReportClientDocument where to find it?

Question2: If not, where does he look for it?

Question3: Is the CRconfig.xml necessary?

I'm attaching the source code that produces the exception.

Thanks in advance,



package crystalreports;

import com.crystaldecisions.ReportViewer.ReportViewerBean;import com.crystaldecisions.reports.sdk.ReportClientDocument;import;import java.awt.BorderLayout;import java.awt.Container;import javax.swing.JFrame;import javax.swing.SwingUtilities;

public class MainClass extends JFrame { private ReportClientDocument reportClientDoc = new ReportClientDocument(); private ReportViewerBean reportViewer = new ReportViewerBean(); private Container cp = null; public MainClass() { } public static void main(String [] args) { SwingUtilities.invokeLater(new Runnable() { public void run() { new MainClass().launchApp(); } }); } public void launchApp() { try { cp = getContentPane(); cp.setLayout(new BorderLayout()); cp.add(reportViewer);"D:
JRCViewReport.rpt", 0); reportViewer.setReportSource(reportClientDoc.getReportSource()); this.setLocation(50, 50); this.setSize(600, 600); reportViewer.init(); reportViewer.start(); this.setVisible(true); } catch(Exception ex) { System.out.println(ex); } }}


Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Sep 25, 2007 at 05:15 AM

    Post Author: Ted Ueda

    CA Forum: JAVA

    The JRC requires CRConfig.xml to be found on the classpath. It holds the license keycode and other configuration information, and so is necessary. Either the containing folder path or the jar file must be listed within the classpath.Sincerely,Ted Ueda

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.