locked
Deploy Farmbased solution as a sandbox RRS feed

  • Question

  • Hello,

    I have created one webpart and deployed as a farm based solution now I want to deploy the same solution as a SandBox solution.Is is possibe ?

    Thanks,

    Saturday, April 12, 2014 10:07 AM

Answers

All replies

  • If the web part doesn't do anything that Sandbox solutions aren't allowed to do, like a Visual Web part, you can deploy it as sandbox solution by changing one setting in the project and recompiling it.  But to the best of my knowledge you will need to repackage it after you switch it to a Sandbox solution.

    Paul Stork SharePoint Server MVP
    Principal Architect: Blue Chip Consulting Group
    Blog: http://dontpapanic.com/blog
    Twitter: Follow @pstork
    Please remember to mark your question as "answered" if this solves your problem.

    Saturday, April 12, 2014 12:12 PM
  • Thanks Paul for your instant reply..

    I have created a simple web part to add,delete and update the data in custom list.So which setting I have to change and in repackage also. Can you please elaborate more?

    Thanks, 

    Saturday, April 12, 2014 12:31 PM
  • In the project properties there is a property called Sandbox Solution with a Value of True (Sandbox solution) or False (Farm Solution).  Just change that property and recompile.  That's all that will be necessary unless your web part tries to use code that isn't available in a Sandbox solution.  In that case it won't compile and you'll need to modify your code to avoid the restriction.  The following article discusses how to find the Sandbox Solution Property to change:

    http://stackoverflow.com/questions/3330240/how-to-change-sharepoint-2010-project-from-sandboxed-solution-to-farm-solution


    Paul Stork SharePoint Server MVP
    Principal Architect: Blue Chip Consulting Group
    Blog: http://dontpapanic.com/blog
    Twitter: Follow @pstork
    Please remember to mark your question as "answered" if this solves your problem.


    Saturday, April 12, 2014 4:02 PM