function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
AbuAbu 

EnterpriseConnection class is missing in WSDL

I have got a Enterprise  WSDL file from my account. From that i have extracted all the Java classes to connect and interact with Salesforce. While implement the Web client i found that i am missing one class Called "EnterpriseConnection". Without that it seems i cannot login to Salesforce.

Today is my first day of Salesforce.  Can anyone please help me out with this. I am desperate to login to my Salesforce acount. have tried to use partner WSDL Where i have found "PartnerConnection" Class. Tried to login using it but asking for "authEndPoint". Couldn't find it anywhere.

Please help me out..

SuperfellSuperfell

EnterpriseConnection is part of WSC. see the getting started guide in the api docs, it has WSC examples.

AbuAbu

Thank you for replying me.

I have gone through the WSC quick start guide. I was getting the following errors for the following command while generating the necessary objects for use in building client Web service applications:

 

M:\jdk1.6.0_20\bin>java -classpath M:\projects-java\salesForceDemo\Referenced Packages\wsc-22.jar com.sforce.ws.tools.wsdlc M:\projects-java\salesForceDemo\Referenced Packages\ente
rprise.wsdl M:\projects-java\salesForceDemo\ReferencedPackages\wsc-22.jar
Exception in thread "main" java.lang.NoClassDefFoundError: ûclasspath
Caused by: java.lang.ClassNotFoundException: ûclasspath
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
Could not find the main class: ÔÇôclasspath. Program will exit.

 

So i have used the Java Eclipse (Web Services-->Web Service Client)wizard to generate all the classes to create WS Client. I am Using Java. 


SuperfellSuperfell

Undoubtly the spaces in your path names are causing chaos, you'll need to either remove the spaces in the names or quote all the strings.

 

If you use another tool to generate the java code, then they all generate different client classes and have different programing models, so sample code is not transportable between tools.

AbuAbu

Thank you for your reply. 

 

You were right, the problem was the file paths. I have managed to run WSDLC tool which has generated a Jar file for me. I have found EnterpriseConnection Class in there. The sample code has two more class which are missing in my Jar. They are-

- ConnectorConfig

-  ConnectionException

 

I have imported the generated .jar file where EnterpriseConnection class resides. I am using eclipse to create a WS client. I need these above files to run the sample code. i couldn't find any help regarding this anywhere. 

It seems you have expertise in this integration. I would be grateful to you if you could give me a solution. I want to create a WS client in eclipse where i want to run the sample code given in the sales force Quick start guide.

 

Thanks for your time.

SuperfellSuperfell

Those classes are in the wsc jar.

BinogBinog

Thank you very much guys, this thread was very helpful to me. I was also able to import WSDL to eclipse, create a jar and make a successful API call.  Hope to read more of you guys here in the boards. I'm just starting to learn integration. :)

gowthamgowtham

am not able get the Enterprise Connection and Connector class in Enterprise.wsdl its urgent please do the need ful thanks in advance

Bhavesh Kabra 7Bhavesh Kabra 7
I am using an plugin of axis2 in eclipse to generate the java classes from wsdl. After completion of the process I am unable to find the same "com.sforce.soap.enterprise.EnterpriseConnection"  in the genrated files. Please clearify if additional parameters are to be provided in wsdl2java process in the plugin way. Please help me