Skip to main content

Notifications

Customer experience | Sales, Customer Insights,...
Answered

Update Entity error - Participating entity record of stage is not valid

Posted on by 40

Hi all,

i'm having an issue in trying to Update an Entity, in particular, i want to update the active stage of an Opportunity in the BPF and i'm having the error:

'participating entity record of stage is not valid'

Here's the code i'm using:

newActiveStageId = (Guid)pathResp.ProcessStages.Entities[activeStagePosition].Attributes["processstageid"];

// Retrieve the process instance record to update its active stage
ColumnSet cols1 = new ColumnSet();
cols1.AddColumn("activestageid");

Entity retrievedProcessInstance = crmSvc.Retrieve("opportunitysalesprocess", processOpp1Id, cols1);

// Update the active stage to the next stage
retrievedProcessInstance["activestageid"] = new EntityReference("processstage", newActiveStageId);
crmSvc.Update(retrievedProcessInstance);

crmSvc.Update(...); is the line affected by the error.

I've not found any usefull suggestion about this kind of error, so if someone can help it would be great.

Thanks for anyone responding.

  • Ilir Peposhi Profile Picture
    Ilir Peposhi 5 on at
    RE: Update Entity error - Participating entity record of stage is not valid

    Hi,

    Make sure all required steps are filled in (note that boolean fields are considered as not compiled if set to No) not only from the current stage till the target stage (obviously without the steps of the target stage) but also those of the previous stages.

    Please try and confirm if this fixed your problem.

  • PS10 Profile Picture
    PS10 428 on at
    RE: Update Entity error - Participating entity record of stage is not valid

    Were you able to resolve the error, i am stuck in the similar situation or may be what solution you applied to move from stage 1 to stage 2 with an auto qualify process on a business process flow. 

    Thanks,

    PS

  • Halson Profile Picture
    Halson 7 on at
    RE: Update Entity error - Participating entity record of stage is not valid

    Hi, i'm facing the same problem. did you manage to fix this?

  • Verified answer
    ajyendra Profile Picture
    ajyendra 1,730 on at
    RE: Update Entity error - Participating entity record of stage is not valid

    Hi,

    Please check is there anything madatory field in that when to switch to not stage and update . like you are in Qualify stage and now from your code you move to purpose stage means you update the stage but check that Qualify stage have some mandatory field . Sometimes it through error if it is not filled. You can check this from your CRM First

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,253 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,188 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans