C# Programming
09-02-2009, 11:14 AM
Hello,
i want to make an application, which runs in the background. But maybe not a service, because i maybe let it run under mono and under linux. And i had a few problems, to start the service...
But now the problem, how can i let my application run in the background? I don't want, that it close itself if it's finished with the "Main-Method", because i have a few events and connections which listen on some ports.
I think it should work with
while(true)
{
}
but doesn't such a loop need a lot of resources??
Thanks
i want to make an application, which runs in the background. But maybe not a service, because i maybe let it run under mono and under linux. And i had a few problems, to start the service...
But now the problem, how can i let my application run in the background? I don't want, that it close itself if it's finished with the "Main-Method", because i have a few events and connections which listen on some ports.
I think it should work with
while(true)
{
}
but doesn't such a loop need a lot of resources??
Thanks