Visual Studio 2010 loses Microsoft.SharePoint.dll reference

I was creating a console application to do some querying on a SharePoint site using Visual Studio 2010. I added the Microsoft.SharePoint.dll assembly from the ISAPI folder from the 14 Hive and I proceeded to code. When I came to compiling the code, I got some errors in the Error List. From the description of the errors, they were telling me that the Microsoft.SharePoint.dll assembly is a missing reference. I am sure I added the assembly into the references folder because the assembly is still there !

Anyways, to solve this problem, I did the following:

In Visual Studio 2010, go to Solution Explorer -> Right (or left depending on mouse configuration) click on the project, select Properties. In the Application tab, change the Target Framework from either:

.NET Framework 3.5 Client Profile to .NET Framework 3.5

OR

.NET Framework 4.0 Client Profile -> .NET Framework 4.0

Done.

Advertisements

One Response to Visual Studio 2010 loses Microsoft.SharePoint.dll reference

  1. prasanas says:

    can u send me sharepoint.dll to prasanas14@gmail.com please i need it

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: