Catching Errors in Windows Services

In Windows Service put a try..catch around InitializeComponent in New constructor to catch and handle any init problems, especially when using components that have external dependencies such as performance counters and message queues. TryInitializeComponent()Catch ex As Exception‘ Log or handle event here‘ if you want to inform the Windows Service Control Manager‘ that the service has [...]

SHARE:

Add comment

Loading