Putting my first scheduler task together...compiled the DLL, moved it to the bin directory. This DLL really does nothing and is just the 'shell' as defined in the Wrox press book. I just want to write a history record, but it just sits, queued, the entire time and even goes overdue in the queue, but nothing else is running. I hope I'm just new to this and it is something very obvious.
My questions are there any ideas on why?
Are there any ideas as to how to better troubleshoot this type of thing?
Are there other sites/info strictly about scheduling?
I even tried putting in an example I found on ASP.NET forums.
Here is the code:
Imports
System.Threading
Namespace
ToDo
Public Class ATask
Inherits DotNetNuke.Services.Scheduling.SchedulerClient
Public Sub New(ByVal objScheduleHistoryItem As DotNetNuke.Services.Scheduling.ScheduleHistoryItem)
MyBase.new()
Me.ScheduleHistoryItem = objScheduleHistoryItem
End Sub
Public Overrides Sub DoWork()
Try
'notification that the event is progressing
Me.Progressing() 'OPTIONAL
DoTask()
Me.ScheduleHistoryItem.Succeeded = True 'REQUIRED
Me.ScheduleHistoryItem.AddLogNote("A scheduled task has run") 'OPTIONAL
Catch exc As Exception 'REQUIRED
Me.ScheduleHistoryItem.Succeeded = False 'REQUIRED
Me.ScheduleHistoryItem.AddLogNote("A scheduled task has failed. " + exc.ToString) 'OPTIONAL
'notification that we have errored
Me.Errored(exc) 'REQUIRED
'log the exception
'LogException(exc) 'OPTIONAL
End Try
End Sub
Private Sub DoTask()
' intentionally left blank
End Sub
End Class
End
Namespace\
Then, the setup in the schedule
Full Class Name: DNNScheduledTask.ToDo.ATask, DNNScheduledTask
Schedule enabled: Yes
Time Lapse 1 minute
Retry: none
Run on event: None
Catch up enabled: No
Object Dependencies: <empty>
Run on Servers: <empty>