Question:在Windows Server 2008 上写代码访问SharePoint 2010 站点集时报错!
Error:The Web application at http://dexter-pc:81/SitePages/Home.aspx 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.
Solution:由于访问SharePoint 2010的程序集必须是X64位的,所以出现此错误。在Visual Studio 2010中的【配置管理器】->【活动解决方案平台】,新建解决方案平台,如图。