Re: start/stop services programatically

From: Steve C. Orr [MVP, MCSD] (Steve_at_Orr.net)
Date: 06/15/04


Date: Tue, 15 Jun 2004 14:08:29 -0700

Simply drag a Windows Service from your server explorer window onto a
webform. This will create a nice simple control on your form and you can
call the start and stop methods on it. You can use the same component
programatically from other classes too. Tip: You may need to use
impersonation to have the necessary permissions to start & stop windows
services.

-- 
I hope this helps,
Steve C. Orr, MCSD, MVP
http://Steve.Orr.net
<vickaiser1@yahoo.com> wrote in message
news:89juc05qfq24r8f3lf1so9tq6udlcc2af8@4ax.com...
> I am creating a setup project for an application and need to edit the
> Metabase.xml file during setup.  Does anyone know of a way to stop and
> then restart services programatically before and after I edit this
> file?
>
> Vic


Relevant Pages

  • Re: Need help with netstat and connections running in background
    ... Right click on the cmd Title bar, point to Edit and click on Select All. ... Alt + Spacebar opens context menu ... You can type in a command prompt: ... How to start Windows in Safe Mode Windows XP ...
    (microsoft.public.windowsxp.general)
  • Re: IE 6 Will not open inside specific User Profile
    ... Click Advanced or Edit, ... You Cannot Open New Internet Explorer Window or Nothing Happens After You ... >I have a client that is running Windows XP Home SP1 on a Dell system. ... > unable to register it because whenever I tried to register it, ...
    (microsoft.public.windows.inetexplorer.ie6.browser)
  • Re: Ohhh....Ramesh, Kelly....Thank you
    ... fixing the rest of the bags edit by either running my edit on line 2 (which ... 2004 Windows MVP "Winny" Award ... > "Ratan Maitra" wrote in message ... > I had read somewhere that "Play all" is actually a link to the default ...
    (microsoft.public.windowsxp.general)
  • Problem with file permissions
    ... >Domain with Windows 2000 server and Windows XP ... >Administrator: Full Control ... >able to edit any other user's file. ... 30 XP workstations, and after testing ...
    (microsoft.public.win2000.security)
  • Re: Simulating KB input in a Windows app, and reading out results
    ... That depends on the target application. ... probably find it by its control ID. ... If it's not the only edit control ... loads of the things you mentioned are found in the help under Windows CE! ...
    (microsoft.public.win32.programmer.ui)