Antipod
Antipod

Reputation: 1643

SharePoint. How to run timerjob every 90 minutes

I have a web.config setting like IntervalInMinutes. I would like to use the setting value to create my SPSchedule instance and run my job. The interval should be set in minutes.

I know how to use SPMinuteSchedule and run the job every 0 < n < 60 minute or how to use SPHourSchedule and run the job every 0 < n < 24 hours, But what if I want to have 90 or 2000 minutes interval as the setting value?

So, the question is: what should I do to run the job with the minutes interval 0 < n < 100000?

Thank you.

Upvotes: 1

Views: 861

Answers (1)

Marek Grzenkowicz
Marek Grzenkowicz

Reputation: 17333

It's not a very robust solution, but I think you'll have to use an appropriate number of the SPDailySchedule objects.

In case of the 90 minutes interval it is:

24 h / 1.5 h = 16

Upvotes: 1

Related Questions