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
MingChang.HouMingChang.Hou 

Import enterprise.wsdl error

I get the enterprise.wsdl file form the Salesforce websit, and then I use vs2005 create a new project(ASP.NET XML Web Service).
I follow the help file(download form salesforce) "Step3. Import the WSDL File Into Your Development Platform" as follow :
 
1. Add a Web reference to your project for the XML Web service that you want to access. The Web reference creates a proxy
class with methods that serve as proxies for each exposed method of the XML Web service.
2. Add the namespace for the Web reference.
3. Create an instance of the proxy class and then access the methods of that class as you would the methods of any other class.
To add a Web reference:
1. On the Project menu, choose Add Web Reference.
2. In the URL box of the Add Web Reference dialog box, type the URL to obtain the service description of the XML Web
service you want to access, such as:
file:///c:\WSDLFiles\enterprise.wsdl
3. Click Go to retrieve information about the XML Web service.
4. In the Web reference name box, rename the Web reference to sforce, which is the namespace you will use for this Web
reference.
5. Click Add Reference to add a Web reference for the target XML Web service. For more information, see the topic “Adding
and Removing Web References” in the Visual Studio documentation.
6. Visual Studio retrieves the service description and generates a proxy class to interface between your application and the
XML Web service.
 
But finish the import step, the vs2005 will auto generate sforce.h and generate error message as follow:
1. error C2143: syntax error : miss ';' (before 'System::String')
        public:  property System::String^  namespace {    -----> this line
            System::String^  get();
            System::Void set(System::String^  value);
        }
 
Does anyone know how to solve this problem?
 
thanks for your help!
 
 
 
 
 
SuperfellSuperfell
I've heard of many problems with the c++ code gen part of WSDL.exe, i think you're only workable solution would be to use c# instead. (you can always package the resulting generated code as a .NET module/.dll and call that from c++).