Here is the code I have:
class Program { static void Main(string[] args) { BackgroundTasks bt = new BackgroundTasks(); while (true) { System.Threading.Thread.Sleep(10000); } } } |
I just want the object of BackgroundTasks to run forever (listening for events), but I feel that causing the main thread to keep sleeping isn't the most efficient way
And yes, I can do this nativally with an extension to services.exe, but I want managed :)
Thanks in advance, Andrew

Run an executable as a background service
BruceWang.Korea
Kind regards, Andrew
RobF
Methark