Anup,
I believe this is a problem with the classloader. You may be able to do
this by adding a JSP page to the viewer plugin that sets the
PARENT_CLASSLOADER key
http://wiki.eclipse.org/Adding_an_Object_to_the_Application_Context_for_the_Viewer_%28BIRT%29
or
BEFORE calling the WebViewer.display () method, call the
WebappAccessor.start () method, as shown here:
WebappAccessor.start (
ViewerPlugin.WEBAPP_CONTEXT,
YourPlugin.PLUGIN_ID,
Path.EMPTY
);
You will see yourplugin.PLUGIN_Id will cause the viewer to use your
plugins classloader. You will have to copy the BIRT directory of the
viewer into your application though, so the first solution may suit you
better.
Jason
Anup Gokhale wrote:
Hi all.
I am exploring using the BIRT Viewer in a RCP app. I have seen and
experimented with the code in org.eclipse.birt.examples.rcpengine and
org.eclipse.birt.examples.rcpviewer . However I haven't been able to
adapt it to my needs. My case is quite simple actually:
1. I have got a RCP app with 5 reports. All reports use the scripted
data set
2. In the RCP app each report alongwith the required eventadapter
classes is placed in a separate package (one package for each report).
3. I have a "Reports" menu with sub menus "Report1"...5
4.I want the Report1 to be opened in the BIRT viewer when the user
clicks on the corresponding menu.
Now each report is rendered fine in the BIRT designer preview, but all
reports show an empty when the RCP app is run. I have have read at
quite a few places about placing my jars and classes under the WEB-INF
folder. But in my case there are no jars as all code is in the RCP app
itself.
Any help on how to proceed?
AGG