web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

System.Runtime.Remoting.RemotingException Object disconnected

(0) ShareShare
ReportReport
Posted on by 310

Hi,

I am using crm online 2015.

I have a custom workflow that uses a foreach loop to iterate Leads and executes some code:

foreach (Entity ent in LeadMailActivities.ToList())
{

//sending emails...

}

The workflow was working fine for one year in my organization. Today, it crashes throwing this exception:

System.Runtime.Remoting.RemotingException: Object '/c78aa5bd_ad2d_4f66_b90c_06a7a9c109e7/82moizgdibj8due1jadvgz1m_11.rem' has been disconnected or does not exist at the server.

  at Microsoft.Crm.Sandbox.SandboxCodeUnit.Execute(IExecutionContext context)

=> It seams that I have a big number of Leads and the garbage collector is cleaning them before Dynamics acheive the operation.

How can I resolve that please ?

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Aiden Kaskela Profile Picture
    19,696 on at

    Hi Mounir,

    If you're concerned that you have two many leads then it may be the workflow that's timing out (2 minute cap), and with CRM Online there's no way to extend the timeout time either. You'll either need to try and make your code more efficient to get in under two minutes, or come up with another solution where you offload the processing to something outside of CRM.

    I'd appreciate if you would mark any helpful answers as Verified.

    Thanks,

     Aiden

  • Rajkumar Rajaraman Profile Picture
    on at

    Refer this thread:

    community.dynamics.com/.../165629

  • Aiden Kaskela Profile Picture
    19,696 on at

    Right, that's everything I suggested.

  • Suggested answer
    ScottDurow Profile Picture
    21 on at

    I have seen this when there is a outage with CRM Online. If the sandbox servers are in the middle of restarting/shutting down then you will get this error mid execution of a workflow activity.

    I suggest waiting a while and if it is still happening - report to Microsoft Support via the Office 365 support portal.

    Hope this helps,

    Scott

  • ScottDurow Profile Picture
    21 on at

    How did you get on? Did the issue get resolved?

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans