+ Start a Discussion

Dynamicall​y update custom object (c#)

I am working in c#, am relatively new to the Salesforce API's and am trying to update a custom object dynamically.  I assume there is some way to retrieve (or create) the object, get its fields collection and update via the collection, something like myOjbect.Fields("status__c) = "accepted".  It's necessary to write it in this way because I won't know the fields to update in advance and therefore can't refer to them explicitly, like myObject.status.  Any direction much appreciated.  (also posted this in .net forum)


It can be achieved using describe calls. Below url helps






David, You can use the Partner WSDL, In which you can create a instance of SObject which takes the XMLElement array (fieldname, value) pair as one parameter, You can also refer to the sample code of using Partner WSDL..