RSS

Category Archives: Error

Resolved: Could not load file or assembly ‘Microsoft.SharePoint.Sandbox, Version=12.0.0.0, Culture=neutral, PublicKeyToken=XXXXXXXXX’ or one of its dependencies…


I have a remote sharepoint solution that contains SharePoint dll’s reference. Whenever I run the solution, start page get crash and show me this error.

“Could not load file or assembly ‘Microsoft.SharePoint.Sandbox, Version=12.0.0.0, Culture=neutral, PublicKeyToken=XXXXXXXX’ or one of its dependencies. An attempt was made to load a program with an incorrect format.”

Well every time I run the project it creates Microsoft.SharePoint.Sandbox.dll and Microsoft.SharePoint.Sandbox.xml inside the bin folder and it creates the problem. Well there are lots many things have written on web regarding this problem. I follow all these things but could not get rid of this error. Finally I decided to fix this problem according to my way. So below are the steps to fix this problem permanently.

1. Inside solution explorer (Visual Studio), select the project and right click on that.

2. From context menu, click on properties.

3. When properties page opens, Click on Build Events.

4. Under Post – build event command line, copy and paste below lines

cd $(TargetDir)

del Microsoft.SharePoint.Sandbox.dll

del Microsoft.SharePoint.Sandbox.xml

Done!

NOTE: please replace with your dll name.

 
 

Error occurred in deployment step ‘Recycle IIS Application Pool’: Provider load failure


The Bug

When you try to deploy or retract a SharePoint 2010 solution from visual studio 10 you get below error message:
Error occurred in deployment step ‘Recycle IIS Application Pool’: Provider load failure

Solution

Restart the SharePoint 2010 User Code Host service resolved the issue. Try below powershell command.

restart-service SPUserCodeV4

 
Leave a comment

Posted by on August 14, 2012 in Bug, Error, Sharepoint Server 2010, Webpart

 

Tags: ,

Sharepoint 2010 Content Deployment Error : Feature ‘XXXXX-XXXX-XXXX’ is Site-scoped, and cannot be added to the Web.


Error:

When you do content deployment of your custom portal in Sharepoint 2010 you might get following error:

Content deployment job ‘Remote import job for job with sourceID = XXX-XXX-XXX-XXX: Import in progressThe exception thrown was ‘System.InvalidOperationException’ : ‘Feature ‘XXX-XXX-XXX’ is Site-scoped, and cannot be added to the Web.’

Cause

This occurs if you delete or retract your custom solution without deactivating and uninstalling  the feature for each deployed scope.

Resolution

You need to cleanup your feature uninstallation. Always follow below steps to uninstall a feature

  • stsadm –o deactivatefeature –id a9efee03-12fc-46ca-acba-0ef1e0ae3171 -url http://site
  • stsadm –o uninstallfeature –id a9efee03-12fc-46ca-acba-0ef1e0ae3171
  • stsadm -o retractsolution -name CustomWebpart.wsp -immediate -url http://site
  • stsadm -o execadmsvcjobs
  • stsadm -o deletesolution -name CustomWebpart.wsp  

You need to do this for all your sites using the feature. Then try content deployment again.

 
2 Comments

Posted by on February 6, 2012 in Error, Sharepoint Server 2010

 

Tags: ,

Cannot connect to the SharePoint site: . Make sure that the Site URL is valid, that the SharePoint site is running on the local computer, and that the current user has the necessary permissions to access the site.


Cause:
You may experience this issue on a development machine when trying to create a SharePoint project using Visual Studio 2010.

From the File menu the developer selected New->Project and then selected ‘Empty sharepoint project’ (SharePoint 2010) and then typed in the url into the dialog box that appeared and then hit the Validate button. Upon clicking the button, the following error message was shown:

Cannot connect to the SharePoint site: http://server:123/. Make sure that the Site URL is valid, that the SharePoint site is running on the local computer, and that the current user has the necessary permissions to access the site.

Solution:

  1. Open up SQL Manager and navigate to Security –> Logins
  2. Select the user that you’re using to create the VS project.if the user is not there, add the user.
  3. Under Server Roles for the user tick as sysadmin

 

 
2 Comments

Posted by on November 2, 2011 in Development, Error, Sharepoint Server 2010

 

Tags: ,

SharePoint Designer 2010 Workflow Activities not updating or How to clear sharepoint Designer cache?


Cause:

You may experience this issue when you try to update sharepoint 2010 workflow using SPD.If you are building a workflow activity on WSS for SPD you may have to update your activity DLL regularly. Some times SPD does not recognize your changes in dll. so you might have to clear your  workflow activity cache from system folder.

Solution:

1. Close your Sharepoint Designer.
2. Navigate to "My Computer"
3. Then go to
 - %System Drive%\Documents and Settings\%user%\ Local Settings\ 
 Application Data\Microsoft\WebSiteCache.
 - %System Drive%\Documents and Settings\%user%\Application Data\
 Microsoft\Web Server Extensions\Cache
4. Search for the folder  that looks similar to the name of the website.
5. Delete the assembly with the name similar to the one you are changing.
6. Start SharePoint designer.
7. This should solve your cache problem.
 
Leave a comment

Posted by on October 25, 2011 in Error, Workflow

 

Tags: , ,

The form cannot be rendered. This may be due to a misconfiguration of the Microsoft SharePoint Server State Service. For more information, contact your server administrator.


You may receive this error when trying to publish a infopath form in SharePoint 2010

The form cannot be rendered. This may be due to a misconfiguration of the Microsoft SharePoint Server State Service. For more information, contact your server administrator.

Cause:
State service is not enabled on Server.You would need to install the ‘State Service’ via the Configuration wizard in Central Administration or via PowerShell.

Solution:
To configure the State Service by using Windows PowerShell:
1. Click Start, Administrative Tools, Windows PowerShell Modules.
2. In Windows PowerShell, type $serviceApp = New-SPStateServiceApplication -Name “State Service”
3. Create a State Service database and associate it with a service application, by typing New-SPStateServiceDatabase -Name “StateServiceDatabase” -ServiceApplication $serviceApp
4. Create a State Service Application Proxy and associate it with the service application by typing New-SPStateServiceApplicationProxy -Name “State Service” -ServiceApplication $serviceApp -DefaultProxyGroup

 

 
Leave a comment

Posted by on October 24, 2011 in Error, Infopath 2010

 

Tags: ,

Visual web part deployment error : – Recycle IIS application pool”: The local sharepoint server is not available


When you try to deploy Visual webpart using Visual studio 2010 you will get following error on deployment :Error occured in deployment step: “Recycle IIS application pool”: The local sharepoint server is not available. Check that the server is running and connected to the sharepoint farm.

Cause:-
The account you are running Visual Studio does not have sufficient permission in SQL server database

Solution:-
Make the account you are running Visual Studio a member of the db_owner role on the sharepoint_config and sharepoint_admin databases.

 

 
2 Comments

Posted by on October 19, 2011 in Error, Visual web part

 

Tags: ,