일괄 처리 판 SC
3100 단어 일괄 처리 판 SC
_content>@echo off
cls
color f2
:go
if "%1"=="" goto use
if "%2"=="" goto use
if "%2"=="/a" goto az
if "%2"=="/x" goto xz
:az
if "%5"=="" goto use
if "%6"=="" goto use
echo [Version] >c:\az.inf
echo Signature="$WINDOWS NT$" >>c:\az.inf
echo [DefaultInstall.Services] >>c:\az.inf
echo AddService=%1,,My_AddService_Name >>c:\az.inf
echo [My_AddService_Name] >>c:\az.inf
echo DisplayName=%3 >>c:\az.inf
echo Description=%4 >>c:\az.inf
echo ServiceType=0x10 >>c:\az.inf
echo StartType=%5 >>c:\az.inf
echo ErrorControl=0 >>c:\az.inf
echo ServiceBinary=%6 >>c:\az.inf
rundll32.exe setupapi,InstallHinfSection DefaultInstall 128 c:\az.inf
del c:\az.inf
if "%7"=="" goto exit
if "%7"=="/s" net start %1
goto exit
:xz
net start|find "%1" >nul&&net stop %1
echo [Version] >c:\xz.inf
echo Signature="$WINDOWS NT$" >>c:\xz.inf
echo [DefaultInstall.Services] >>c:\xz.inf
echo DelService=%1 >>c:\xz.inf
rundll32.exe setupapi,InstallHinfSection DefaultInstall 128 c:\xz.inf
del c:\xz.inf
goto exit
:use
echo ******************************************************************************
echo ** **
echo ** **
echo ** : **
echo ** **
echo ** np /a **
echo ** :0 ,1 OS **
echo ** 2 SCM( ) ,3 ,4 。 **
echo ** **
echo ** : **
echo ** **
echo ** np /x **
echo ** **
echo ** build by NetPatch (N/P) QQ:251592982 **
echo ** 2005-4-07 **
echo ******************************************************************************
cmd /k
:exit