on 03-11-2006 11:32 PM
Hey Guys,
When running the program
[code]import com.sap.mw.jco.*;
public class TutorialConnect1 extends Object {
JCO.Client mConnection;
public Connect1() {
try {
// Change the logon information to your own system/user
mConnection =
JCO.createClient("100", // SAP client
"RFCUSER2"// userid
"RFCUSER2", // password
null, // language
"LABR3", // application server host name
"00"); // system number
mConnection.connect();
System.out.println(mConnection.getAttributes());
mConnection.disconnect();
}
catch (Exception ex) {
ex.printStackTrace();
System.exit(1);
}
}
public static void main (String args[]) {
Connect1 app = new Connect1();
}
}
[/code]
I get the exception
[code]java.lang.NoClassDefFoundError
at com.sap.mw.jco.MiddlewareJRfc$Client.connect(MiddlewareJRfc.java:836)
at com.sap.mw.jco.JCO$Client.connect(JCO.java:3159)
at com.ids.jco.JCOUtil.getClient(JCOUtil.java:37)
at com.ids.jco.JCOUtil.main(JCOUtil.java:23)[/code]
My program in the developer studio compiles just fine, I have added all the libraries in the developer studio. In the "set additional libraries" context menu of the project I have included all the libraries.
In the Debug/Run settings I see all the libraries included when I test the program.
I am running the program on Netweaver Developer Studio SP15
Any help is appreciated.
Regards
Sumit.
Hi,
Please add the following jar to the classpath
<Drive>:/usr/sap/<SID>/JC00/j2ee/cluster/server0/bin/ext/com.sap.mw.jco/jrfc.jar
Hope that helps.
Regards,
S.Divakar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
89 | |
10 | |
9 | |
9 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.