Windows Service Questions
-
I am writing a program in Visual C# Express 2005, and I need to know if it can be done the way I am doing it. Here a my couple concerns: 1.) I have my Windows Forms app and a Windows service compiled into the same EXE. Will that affect my performance in any way? Or render anything unusable? At this point, the service appears in the Services console (services.msc) but I am unable to Start it. 2.) I need to install this service on multiple computers on my domain.... at runtime of my main form. Is there any way I can do this? Or would I have to install the service over the network ina script? My account is administrator of the other computers, so I should be able to do this, I think. 3.) If anyone knows of any easier way to run a couple of DOS commands on a large group of remote computers, rather than a Windows Service, could you tell me? I'd be much obliged. Thanks to any who can answer any of these questions for me. I know it's a pain, so thanks. -MartyExodus
-
I am writing a program in Visual C# Express 2005, and I need to know if it can be done the way I am doing it. Here a my couple concerns: 1.) I have my Windows Forms app and a Windows service compiled into the same EXE. Will that affect my performance in any way? Or render anything unusable? At this point, the service appears in the Services console (services.msc) but I am unable to Start it. 2.) I need to install this service on multiple computers on my domain.... at runtime of my main form. Is there any way I can do this? Or would I have to install the service over the network ina script? My account is administrator of the other computers, so I should be able to do this, I think. 3.) If anyone knows of any easier way to run a couple of DOS commands on a large group of remote computers, rather than a Windows Service, could you tell me? I'd be much obliged. Thanks to any who can answer any of these questions for me. I know it's a pain, so thanks. -MartyExodus
MartyExodus wrote:
I have my Windows Forms app and a Windows service compiled into the same EXE
Why? It's not that hard to separate them into different projects.
MartyExodus wrote:
If anyone knows of any easier way to run a couple of DOS commands on a large group of remote computers
You will definitely have to have an NT service on each computer. And you should definitely have to install the service on each computer by script. The script's not that hard, just installutil. But you say DOS commands almost like you're using System.Diagnostics.Process[^] to run stuff from the command prompt. In that case, why not just write a quick VBScript and run it on each computer?