Wednesday 23 May 2012

Sharepoint 2010 References Issues with Visual Studio 2010

f you are using Visual Studio 2010 for developing the Sharepoint 2010 solutions,especially the tools(console or windows) for backend operation.Then you may have noticed that Visual Studio will not recognise the references of the Sharepoint dll even though you have added the reference to the VS 2010 and it will through the exception as "The web application could not be found" error when ever it will try to access Sharepoint stuff. For which you can't continue your development job.
HOW TO SOLVE THIS ISSUE
STEP 1 - Open the Console or Windows Application in VS 2010
 
STEP 2  - Go to Solution Explorer
 
STEP 3 - Open the Properties of your Project
 
STEP 4 - Click on Build from the left side menu
 
STEP 5 - Change the platform target as x64  (Note: AS Sharepoint 2010 is used to run on the 64 BIT Environment)
 
STEP 6 - Save the changes
 
STEP 7 - Now add the Sharepoint references to your project (like Microsoft.Sharepoint)

No comments:

Post a Comment