We have written a custom windows service (VB.NET, .NET Framework 2.0) that takes a while to start up, because it uploads sales.
Protected Overrides Sub OnStart(ByVal args() As String)
-- upload sales here
End Sub
That fact that it takes a long time to start up is fine, but that generates a time-out error in Windows and another program starting up does not get added to the system tray.
We can delay the sales upload, but would rather have Windows ignore the fact that this service takes a long time to start and not generate an error. Any ideas?
Start the upload sales code on another thread, that’ll run the upload code in the background and let the service respond that its started and you wont get the timeout message
eg