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
MazAMazA 

CS0117: 'site.sforce.Lead' does not contain a definition for 'Amount__c'

Hi everyone,
 
I've been using webservices to connect to salesforce (CRM) API for over a year now and today I added a new field 'Amount' to the salesforce and extracted the WDSLfile. On my local system running Window XP I did a Web References Update and everything worked fine. However, on our production server running Windows 2003 Server I got the following error message.
CS0117: 'site.sforce.Lead' does not contain a definition for 'Amount__c'
Ex.
...
lead.Description = Description;
lead.Amount__c = Amount;  // Only this fails. Works when I remove this line.
...
Why is that? Why on Windows 2003 Server and not on XP? I restarted IIS services as well too and still get the same problem.
Any suggestions?
 
Thanks
Maz.
 
Gareth DaviesGareth Davies

I take it that you are using Enterprise WSDL?

If  you are .Net 2.0 you may be doing JIT compilation on the server which may also need an updated copy of the "web reference" using the new WSDL if you have installed as a project on the server. Perhaps that'll fix it?

G.

MazAMazA
I copied all the references over too and still same thing. I fixed it by removing the whole thing from being in a namespace ??????? no idea why.
 
Thanks again
Maz.