CreateRequest accRequest = new CreateRequest();
Account acc = new Account { Name = “Joe Gill” };
accRequest.Target = acc;
emRequests.Requests.Add(accRequest);
UpdateRequest failRequest = new UpdateRequest();
Account accFail = new Account();
failRequest.Target = accFail;
emRequests.Requests.Add(failRequest);
CreateRequest ctRequest = new CreateRequest();
Contact ct = new Contact { LastName = “Gill” , FirstName=“Joe” };
ctRequest.Target = ct;
emRequests.Requests.Add(ctRequest);
ExecuteMultipleResponse emResults = (ExecuteMultipleResponse)_orgService.Execute(emRequests);
foreach (var rep in emResults.Responses)
{
if (rep.Fault != null)
Console.WriteLine(“Failed “ + rep.Fault.Message) ;
else
Console.WriteLine(rep.Response.ResponseName);
}