cancel
Showing results for 
Search instead for 
Did you mean: 

Sharing Application Ressources

Former Member
0 Kudos

Hello Everybody,

iam working within a WebDynPro Project and get the Exception "ClassNotFound Exception"

when i instantiate a class of a another application.

The Projects of the other application are checked out of the repository and there is no error

by importing the packages.

<b>I think that in running time, the classes of the other application cannot be found,

but how can i give webdynpro information about where the classes of the other application are?</b>

Thanking you in anticipation.

AE

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

thank you for your quick answers!

i tried to solve the problem by selecting the "checked out" projects ->right mous button and "export" as *jar file.

then i add this *jar file to my webdynpro project by properties->java build patth->add external jars.

but finally, "ClassNotFoundException".

I found out, that most projects show the warning: "classpath entry will not be exported. runtime classnotfoundexceptions

may result".

what does this warning mean?

Former Member
0 Kudos

Hi,

If you are using local/remote DCs then you need to follow the procedure explained by me. If it is normal webDynpro(2004s) project then you can add it in build path, which will be available at runtime also.

Regards,

Charan

Former Member
0 Kudos

Hi,

If you are using a class and that class is deployed as part of another application. If that class is part of some external jar then you need to follwo the below procedure:

We can add external jars to this External Library DC. As this DC is non deployable DC we need to create two public parts. One public part is for compilation purpose (API) and another for runtime purpose (SDA deployable).

API Pubic part:. We need to add this as used dc in WebDynpro DC for design time purpose.

SDA Public part: We need to deploy this as part of some other EAR.

For deploying the SDA Public part there are two ways.

As WebDynproDC also contains an EAR we can deploy this as part of WebDynpro DC. For this we need to add this SDA public part to WebDynpro DC as used dc.

Note: If we are deploying into local server, then we should not deploy using RightClickOnDCàDeploy or RightClickApplicatonàDeploy New Archive and Run.

We should deploy using RightClickOnDC à Development Component à Deploy. If not the external jar will not be deployed into the server.

Help: /people/bala.krishnan2/blog/2006/09/25/bid-adieu-to-bots--using-captchas

2. Create J2EE Library DC which is deployable dc, now add the SDA public part of External library dc to this J2EE library dc as used dc and deploy this J2EE lib dc into the server.

Give the library reference of this J2EE lib dc in the WebDynpro DC as u2018u2019sap.comtestjarsu201D (RightClickOnDC>Properties>WebDynpro References-->Library References)

Help: /people/bertram.ganz/blog/2008/11/24/how-to-use-external-jar-files-in-web-dynpro-development-components

For example if we want to use a class which is deployed as part of J2EE EAR dc then we need to give the shared reference of that dc in the below location:

RightClickon Dc>Properties>WebDynproReferences-->SharedReferences

Regards,

Charan

Former Member
0 Kudos

Are you working with NWDI?

use the Develepment Component Metadata to indicate what other DC you are going to need at development and runtime.

http://help.sap.com/saphelp_nw04/helpdata/en/da/92036e9dcb164c8cf1fba50a0cfbf5/frameset.htm

If you are working wiht a WD simple project you can copy the libs on the lib folder of the project and then on the properties indicate where are those libs on the Java Build Path -> Add JARs