Cannot load Microsoft.SharePoint.Library from a Web Service on a Windows XP machine

Oct 1, 2009 at 2:55 AM

Greetings,

I'm developing a web service application using Windows XP development environment.  I'm using Microsoft.Sharepoint.dll which I manually copied from a server running Windows Server 2003.  When I run the web service and invoke a web method, I receive the following error:

System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.SharePoint.Library, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies. The system cannot find the file specified.
Is there any resolution for this in my development machine (which only runs Windows XP)?
Here is the whole stack trace in case you want to know:
System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.SharePoint.Library, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies. The system cannot find the file specified.
   at TE.Data.DisplayDepartmentDLWSS.DepartmentDisplay(PTEntity ptEntity)
   at TE.Workers.DisplayDepartmentWorker.DisplayDepartment(PTEntity ptEntity) in C:\Workspace\K2\TE\TE.Workers\DisplayDepartmentWorker.vb:line 14
   at TE.Managers.PTManager.GetDepartment(PTEntity ptEntity) in C:\Workspace\K2\TE\TE.Managers\PTManager.vb:line 25
   at TestWebService.Service1.GetDepartment(String firstName, String middleName, String lastName) in C:\Workspace\K2\TE\TestWebService\Service1.asmx.vb:line 25
Any help and relevant discussion in this topic is very much appreciated.  Thank you very much Sharepoint experts.


        
    
Oct 1, 2009 at 9:44 AM

Hi yoitsfrancis,

You cannot use Sharepoint Object Model without SharePoint installation(check system Requirements http://technet.microsoft.com/en-us/library/cc288751.aspx#section2) . If you want to to interact with Sharepoint from a remote client, then the best way is to use Sharepoint Web Services. 

Thanks

Appaji