C# Windows Service Question...

  • Thread starter Shawn Buchanan-Cook
  • Start date
S

Shawn Buchanan-Cook

Hello,

I have created a windows service that executes a application (that has a
user interface), and therefore I have the "Allow service to interact with
desktop" checked...

I have found that because of the "Allow service to interact with desktop"
flag being turned on, I can not restart/reboot my system....

I do have the CanShutdown flag in my service set to "true"...

I have noticed that if I turn off the "allow service to interact with
desktop" flag, I am able to restart/reboot my system.... but, I need this
flag turned on...

Can anyone help my with this problem?

Thank you
 
S

Shawn Buchanan-Cook

Hello all,
I figured out my problem...
It was because the process that I was launching from my service had a
winform which I did an override of the close to minimize to the system tray
instead of close out. I found that if all the applications do not close on
your desktop, the operating system will not shutdown... problem resolved...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top