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
Micky MMicky M 

Salesforce WSDL

Hi All pardon my ignorance but im really new to java so there may be an obvious answer to this. Im trying to consume that salesforce enterprise wsdl to access a method that ive written in salesforce. I created a java aplication then selected new web service client. All seems to be going ok then i get this :

 


[WARNING] src-resolve: Cannot resolve the name 'ens:sObject' to a(n) 'type definition' component.
  line 12766 of file:/Users/mickmurphy/NetBeansProjects/JavaWSDLImportTest/xml-resources/web-service-references/enterprise/wsdl/enterprise.wsdl#types?schema2

[ERROR] A class/interface with the same name "javawsdlimporttest.Ayout" is already in use. Use a class customization to resolve this conflict.
  line 13912 of file:/Users/mickmurphy/NetBeansProjects/JavaWSDLImportTest/xml-resources/web-service-references/enterprise/wsdl/enterprise.wsdl

[ERROR] (Relevant to above error) another "Ayout" is generated from here.
  line 13537 of file:/Users/mickmurphy/NetBeansProjects/JavaWSDLImportTest/xml-resources/web-service-references/enterprise/wsdl/enterprise.wsdl

[ERROR] Two declarations cause a collision in the ObjectFactory class.
  line 13912 of file:/Users/mickmurphy/NetBeansProjects/JavaWSDLImportTest/xml-resources/web-service-references/enterprise/wsdl/enterprise.wsdl

[ERROR] (Related to above error) This is the other declaration.   
  line 13537 of file:/Users/mickmurphy/NetBeansProjects/JavaWSDLImportTest/xml-resources/web-service-references/enterprise/wsdl/enterprise.wsdl

[ERROR] Two declarations cause a collision in the ObjectFactory class.
  line 9391 of file:/Users/mickmurphy/NetBeansProjects/JavaWSDLImportTest/xml-resources/web-service-references/enterprise/wsdl/enterprise.wsdl

[ERROR] (Related to above error) This is the other declaration.   
  line 9387 of file:/Users/mickmurphy/NetBeansProjects/JavaWSDLImportTest/xml-resources/web-service-references/enterprise/wsdl/enterprise.wsdl

[ERROR] Two declarations cause a collision in the ObjectFactory class.
  line 9392 of file:/Users/mickmurphy/NetBeansProjects/JavaWSDLImportTest/xml-resources/web-service-references/enterprise/wsdl/enterprise.wsdl

[ERROR] (Related to above error) This is the other declaration.   
  line 9388 of file:/Users/mickmurphy/NetBeansProjects/JavaWSDLImportTest/xml-resources/web-service-references/enterprise/wsdl/enterprise.wsdl

Has anyone had this before and if so what did you do to resolved the problem? Any help would be much appreciated.

 

Thanks.

Santhosh KumarSanthosh Kumar

Try Force.com WSC connector, which let's you bridge the WSDL to Java. This is similar to wsdl to java tools, but specific to Salesforce api.