When we create the Console applications in SharePoint 2010 Server, their application kept on getting the following error, when trying to create a new instance of SPSite:
System.IO.FileNotFoundException: “The Web application at http://sharepointsite could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application.”
To fix this in SharePoint 2010, there are a few things that should be done:
1. Under Project Properties –> Application, Ensure that the target framework to be compiled against is .NET Framework 3.5
2. Under Project Properties –> Build, Ensure that the platform target is set to x64
3. Ensure that the SPSite URL you are trying to open is in your Central Admin –> Web Application alternate access mappings
System.IO.FileNotFoundException: “The Web application at http://sharepointsite could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application.”
To fix this in SharePoint 2010, there are a few things that should be done:
1. Under Project Properties –> Application, Ensure that the target framework to be compiled against is .NET Framework 3.5
3. Ensure that the SPSite URL you are trying to open is in your Central Admin –> Web Application alternate access mappings
No comments:
Post a Comment