Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 82002

Collection Was Modified Error in WCF using Organization Service.

$
0
0

Hi Team,

We do have Dynamics CRM 2016 on-prem implementation. There is webapi service which consumes Dynamics Organization service.

On local development environment we do not get any error, but when we deploy it on test or production environment we get 'Collection was modified; enumeration operation may not execute' error.

We get this error even for simple retrieve (which does not include any list or entitylist).

Code which returns error

context.Opportunity.FirstOrDefault(d => d.opportunityid == oppId); 

context.OrganizationService.Retrieve(incident.EntityLogicalName, incidentId, columnset).ToEntity<incident>()

Any inputs will be highly appreciated.


Viewing all articles
Browse latest Browse all 82002

Latest Images

Trending Articles



Latest Images