on 09-25-2008 6:52 AM
Hai friends,
I have created a web dynpro application ,,,, I created one java class ...
how can i call that class in view class...
Can anybody help me................
Thanks in advance.
Regards
Krish.
Hi Krish
give ur name of java project into project refrences property of
ur webdynpro project. nw u can import java class in ur WD project directly.
Regards,
Khushboo
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Krish,
You can simply import that java class into your view implementation .
Regards
Sreedhar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Add jar file of java class to the web dynpro application properties>java build path-libraries---add jars
and then create object of that class in in web dynpro implemention.
hope it will help u.
Thanks
Abhilasha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
If the WD application is of DC type .always use the jar file (java class) by creating an external library DC,expose it public.
Then Reuse this DC in your WD DC.
This will avoid the mess of runtime errors.The external library DC needs to be deployed explicity on SAP WAS after any change .
KR,
Swathi
Do offer pts:-)
Hi,
Create your class under the src->packages folder using the navigator
Call this class from the view
Ex: Class
package com.sap.demo;
public class Test {
public String callMe()
{
return "Hi";
}
}
usage in view/controller
Test t = new Test();
t.callMe();
OrganizeImports is needed to resolve the class
Regards
Ayyapparaj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi!
you have to add your java class in the package .
for that go to navigator -->select that respective project > src>package.place your java class here.
thanks
vishal
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi..
You paste your java class in folder src-->packages -
><your package name > <your java class > from navigator perspective ....
in your webDynpro application
Now from your view you can create the object for that class and can use it ...The methods of that class are also available
If any errors you say Organize imports ..which solves the problem
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.