Search This Blog

Wednesday, May 20, 2015

Timer Job with Sharepoint

Timer Job:

Timer Job is a background process that are run by SharePoint. It is a periodically executed task inside SharePoint Server. It provides us a task execution environment.

Default Timer Jobs inside SharePoint:

There are many timer jobs inside SharePoint which do internal tasks like:
    • Send emails
    • Validate sites
    • Delete unused sites
    • Health analysis
    • Product versioning
    • Diagnostics
These tasks will having execution periods like:
    • Minute
    • Hour
    • Day
    • Week
    • Month
Components of Connectable web parts : 
  1. Derive CustomTimerJob Class from SPJobDefinition
  2. Add the three Constructors of the derived class : When ever we create the object of CustomTimerJob  class, corresponding constructor will execute.
  3. Override the Execute method: When ever the timer job start running then the code inside the Execute method will run.
  4. We need to create a Feature and Feature Receiver so on activation of this feature we are going the add our timer job to SharePoint farm.

No comments:

Post a Comment

Restricting Custom People Picker to only one Sharepoint group programatically

Refer the following script files in your page,     <!-- For People Picker -->     <script type="text/javascript" src...