How can i restart a window service in windows 7
i have window service application in C#.NET i want to restart my winservice with another application plz anyone can tel how can i do this plz reply thanks
February 25th, 2010 9:17pm
Hi, simly run "net stop <servicename>" to stop the service and "net start <servicename>" to start the service. .net framework also includes classes to natively start/stop services: http://www.dotnetspider.com/resources/865-How-start-stop-windows-services-programmati.aspx André"A programmer is just a tool which converts caffeine into code"
CLIP- Stellvertreter http://www.winvistaside.de/
Free Windows Admin Tool Kit Click here and download it now
February 26th, 2010 2:12am
Thanks Andre.Ziegler my application is unable to start service in windows 7 when user controls are on but with Xp and older version it is working fine
February 26th, 2010 4:19pm
sure, with UAC turned on you have standard user rights and under XP you've used an account with administrator rights! So change the requestedExecutionLevel entry inside the manifest of your application to requireAdministrator. When you start the application, you have to accept the UAC prompt to get administrator rights for your application, so that you can start/stop the service. André"A programmer is just a tool which converts caffeine into code"
CLIP- Stellvertreter http://www.winvistaside.de/
Free Windows Admin Tool Kit Click here and download it now
February 26th, 2010 7:18pm
my app is running on client's computer. Is there any way UAC don't promt to get administrator rights for my application and service starti am very thanks full to you for your coperation Ziegler
February 26th, 2010 8:39pm
you can use the taskscheduler to start your application with admin rights: http://www.msfn.org/board/topic/135472-faq-what-is-the-uac-part2/ André"A programmer is just a tool which converts caffeine into code"
CLIP- Stellvertreter http://www.winvistaside.de/
Free Windows Admin Tool Kit Click here and download it now
February 26th, 2010 11:43pm
Sorry i came back too late Thanks for the help now my app is working thanks u a lote
March 6th, 2010 7:59pm