Jump to content

how to Uninstall a Service?


Recommended Posts

hello

how do i uninstall a service?

i prefer simple ways...

An autoit service or another ? Posted Image

Otherwise you can stop it and disable it !

_StopService ( "Java Quick Starter" )
_SetServiceStartMode ( "Java Quick Starter", 4 )

Func _StartService ( $_ServiceName )
    RunWait ( @ComSpec & ' /c net start "' & $_ServiceName & '"', "", @SW_HIDE )
EndFunc ;==> _StartService ( )

Func _StopService ( $_ServiceName )
    RunWait ( @ComSpec & ' /c net stop "' & $_ServiceName & '"', "", @SW_HIDE )
EndFunc ;==> _StopService ( )

Func _SetServiceStartMode ( $_ServiceName, $_StartMode )
    If $_StartMode > 1 And $_StartMode < 5 Then _ ; 2 = auto , 3 = manual , 4 = disable
    RegWrite ( "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\" & $_ServiceName, "Start", "REG_DWORD", "0x0000000" & $_StartMode )
EndFunc ;==> _SetServiceStartMode ( )
Edited by wakillon

AutoIt 3.3.14.2 X86 - SciTE 3.6.0WIN 8.1 X64 - Other Example Scripts

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...