Sandboxed code execution request failed.

This question is answered This question is answered

I am trying to upload a wsp file to Office 365 Enterprise version.

The solution activates without any error but when I try to activate the feature, I get the  following error:

"Sandboxed code execution request failed."

My solution has an Event Receiver attached to my Feature which has Server Side code in it. Whenever that code comes into context, Office 365 gives me the error.

If I remove the event receiver (ie the code) from the solution and then activate the solution(and the feature), It works fine.

And I should also mention that the solution works fine on many other Sharepoint 2010 installations. It only fails on Office 365.

So my question is: Is code execution not allowed inside O365 right now? or am I doing something wrong?

Verified Answer
  • Sandbox solutions will only activate if you have resource allocated to the site collection the custom solution resides in. You can check this from the Tenant admin page (http://domain-admin.sharepoint .com) and click on Site Collections on the left side of the page. Activate the checkmark box on the left of the site collection and then click on Resource Usage Quota on the Ribbon. The text box at the top is the amount of resources you have allocated, the number below that is the resources available. Click on save after you have made your changes and then attempt to activate your solution.

    If it doesn't work then, there may be a function in the code that is being blocked from running by SharePoint.

All Replies
  • Hi Vardhaman,

    Although SharePoint Online allows customers to upload custom solutions, not all solutions will work in the sandbox.

    Thanks

  • Sandbox solutions will only activate if you have resource allocated to the site collection the custom solution resides in. You can check this from the Tenant admin page (http://domain-admin.sharepoint .com) and click on Site Collections on the left side of the page. Activate the checkmark box on the left of the site collection and then click on Resource Usage Quota on the Ribbon. The text box at the top is the amount of resources you have allocated, the number below that is the resources available. Click on save after you have made your changes and then attempt to activate your solution.

    If it doesn't work then, there may be a function in the code that is being blocked from running by SharePoint.

  • I am also facing similar problem. I believe in my case it is some function in the code that is getting blocked.

    Can we view some detail error message somewhere to track the exact source of the problem?

  • hi I am having the same problem but in my case the Your resource quota is 500 server resources. Solutions can consume resources and may be temporarily disabled if your resource usage exceeds your quota.

    Current Usage (Today)    

    Average Usage (Last 14 days)  

    it is not working at all on reading and I can not tell if it is working at all no reading any help thank you chris byron koalatcut@msn.com

    0 out of 1 people found this post helpful.

  • I am facing the same error"Web Part Error: The request to execute code in the sandbox failed."while saving properties of a web part.

    0 out of 1 people found this post helpful.