Back

Resolving dependency could not be found issues in Sharepoint Portal Server

Problem:
I'm using Visual Studio .NET on a remote computer, I have a reference for local copy of Microsoft.SharePoint.dll but when I build the project I get the following messages in the build errors:

The dependency 'Microsoft.SharePoint.Security' could not be found.
The dependency 'Microsoft.SharePoint.Dsp' could not be found.
The dependency 'Microsoft.SharePoint.Library' could not be found.

Solution
This is a dependency issue. Embedded in the Microsoft.Sharepoint.DLL assembly is a reference to those other DLLs. When you compile your application, you will need those DLLs as well.

You need to extract the files from GAC in the SharePoint (WSS or SPS) machine.
The easiest way to get to the files is througn command line

c:\Windows\Assembly\GAC\Microsoft.SharePoint\version_number

you then just copy it to some place in the dev machine and reference it.

Each Dll in the GAC has its own directory so you need to go to:

c:\Windows\Assembly\GAC\Microsoft.SharePoint.Dsp\[version]

c:/windows/assembly/gac/Microsoft.Sharepoint.Security/
11.0.0.0__71e9bce111e9429c/Microsoft.Sharepoint.Security.dll

Watch out for the double underscore.

Back


Make a Comment on this Article

Your Name:
Comment: