I've generated a C# file with classes wrapping the Salesforce Enterprise API by downloading the enterprise.wsdl file from my organization's Salesforce website to my PC, and running .Net's wsdl.exe utility on it.
My issue is that the generated SforceService.cs file has 262000+ (!!!) lines of code!
All I need to do is be able to execute a single, simple
SELECT Name FROM Account WHERE [critera] SOQL query. Committing a 200k+ line source file to my project just for this seems like significant overkill.
My question is: What's the best way to go about reducing the SforceService.cs file to only what I need?
- Should I manually remove some stuff from the enterprise.wsdl file before running wsdl.exe on it to generate the .cs file? If so, how can I determine what can be pared out? Is there documentation on this somewhere?