I have a solution that has three projects. One is a service, one is a form, and one is a class librar开发者_如何转开发y.
I use the form for debugging, my logic is complete now I would like to just call.
Protected Overrides Sub OnStart(ByVal args() As String)
Dim Logic As New ProcessMail
workTimer = New Timer(New TimerCallback(AddressOf Logic.ProcessMessages), Nothing, (1000 * 60 * 10), (1000 * 60 * 10))
MyBase.OnStart(args)
End Sub
So it fires off my code every 10 minutes. Why wont this work?
The service installs, I see it but it starts and stops, can anyone help me out with what I am doing wrong?
Check the event log. Frequently, a windows service will stop because an exception is thrown.
精彩评论