3

From what I understand from the sparse documentation on MSDN, the way to do long running jobs in SharePoint is to use a SPWindowsService. I would like an example on how to create a custom windows service to run in the context of a SharePoint farm.

kjv
  • 11,047
  • 34
  • 101
  • 140

2 Answers2

0

The following MSDN article should give enough information about how to integrate Windows Services with SharePoint and use the SPWindowsService class.

http://msdn.microsoft.com/en-us/magazine/dd569748.aspx

Peter O.
  • 32,158
  • 14
  • 82
  • 96
Thomas
  • 1
  • 1
0

Instead of SPWindowsService you should create a custom SharePoint Timer Job that executes periodically or once. There are quite a few examples out there on the web, but start with Andrew Connell's examples and go from there:

MSDN Visual How To: Creating, Deploying, and Debugging Custom Timer Jobs in Windows SharePoint Services 3.0 Learn how to harness the power of custom timer jobs in Windows SharePoint Services 3.0. http://msdn2.microsoft.com/en-us/library/cc427068.aspx

Doug Perkes
  • 135
  • 1
  • 7
  • 1
    I am aware of SharePoint Timer Jobs, but I do not wish to use them, as I have already specified in a reply to a comment to my question. I have good reasons why I wish to use a fully custom service. – kjv Oct 10 '09 at 10:03