SharePoint Pitfalls: Creating a Visual Studio Project Without SharePoint Locally Installed

This is the first on a (huge) collection of posts on SharePoint pitfalls. Hope you enjoy, and, please, do send me your feedback!

If you do not have SharePoint locally installed, Visual Studio will not let you create a SharePoint project:


Fortunately, it is easy to go around this in two simple steps:

  1. Registry

    In the Registry, add the following key: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\SharePoint

    In it, add two string values: Location=C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\ and SharePoint=Installed

  2. Global Assembly Cache

    Copy the following assemblies from a machine where SharePoint is installed (C:\Windows\Microsoft.NET\Assembly\GAC_32) into your development machine and add them to the GAC (gacutil):

    • Microsoft.SharePoint.dll
    • Microsoft.SharePoint.Client.dll
    • Microsoft.SharePoint.Client.Publishing.dll
    • Microsoft.SharePoint.Client.Runtime.dll
    • Microsoft.SharePoint.Client.ServerRuntime.dll
    • Microsoft.SharePoint.Library.dll
    • Microsoft.SharePoint.Linq.dll
    • Microsoft.SharePoint.Portal.dll
    • Microsoft.SharePoint.Publishing.dll

    Of course, you may need others as well.




  • On the machine I use where Sharepoint is installed, the path to the DLLs is C:\Windows\Microsoft.NET\assembly\GAC_32, not

  • It is in point of fact a great and helpful piece of info. I am happy that you shared this useful info with us. Please stay us up to date like this. Thanks for sharing.

  • This seems really cool, unfortunately I have not been able to get it work. Now for the stupid questions :); will this work with .dlls' from a trial SP2013 version on a VM dev environment? My local client SP dlls' are in the ..\15\ISAPI\, I have tried putting the dlls' in both folders; \15\ and \15\ISAPI\ and adjust the value for the location accordingly but no luck.
    Let me know what you think and thanks,

  • Kurt: the assemblies need to be in the GAC, doesn't really matter which folder they are. And yes, DLLs from a trial SP should work, they are the same.

  • Running on 64 bit Windows 7 Professional...This does not seem to work with VS 2015. I do not have older VS to try.

  • Doesn't work :(

  • Thanks for the info it really help, This will work on windows 7, I have windows, what I done is
    1. HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\
    and add two key
    Location=C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\
    copy DLL with its folders from server where I have SP 2013 installed
    and go to
    due to some the DLL already there so I did not replaced the one already there just add missing once from the 9 DLL.
    this shpould work.

  • Thanks, Erkindunya!

  • @erkindunya is correct --
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\
    - not -
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\15.0\SharePoint

  • I have tried all the steps mentioned but no luck. I am using visual studio 2017. Is that the reason. Please help

  • Vijaya: yes, it only works in older versions of VS.

  • Not work, Mine is VS 2012 on Win 10. Any sugestion, thank u..

Add a Comment

As it will appear on the website

Not displayed

Your website