中国DOS联盟论坛

中国DOS联盟

-- 联合DOS 推动DOS 发展DOS --

联盟域名:www.cn-dos.net  论坛域名:www.cn-dos.net/forum
DOS,代表着自由开放与发展,我们努力起来,学习FreeDOS和Linux的自由开放与GNU精神,共同创造和发展美好的自由与GNU GPL世界吧!

游客:  注册 | 登录 | 命令行 | 会员 | 搜索 | 上传 | 帮助 »
中国DOS联盟论坛 » DOS批处理 & 脚本技术(批处理室) » Reg To Bat 完美版 能生成卸载和安装批处理
作者:
标题: Reg To Bat 完美版 能生成卸载和安装批处理 上一主题 | 下一主题
xwlzx
新手上路





积分 1
发帖 1
注册 2007-12-4
状态 离线
『楼 主』:  Reg To Bat 完美版 能生成卸载和安装批处理

@echo off
color 0a
reg query HKCR\REGfile\shell\RegToBat\command
if %errorlevel%==0 goto jump
set CPath=%~0
set CPath=%CPath:\=\\%
echo REGEDIT4>"%TEMP%\RegYJ.reg"
echo [HKEY_CLASSES_ROOT\regfile\shell\RegToBat\command]>>"%TEMP%\RegYJ.reg"
echo @="\"%CPath%\" \"%%1\"">>"%TEMP%\RegYJ.reg"
regedit /s "%TEMP%\RegYJ.reg"
del /q "%TEMP%\RegYJ.reg"
reg add HKCR\REGfile\shell\RegToBat\command /ve /d "\"%0\" \"%%1%\"" /f
echo intAnswer = Msgbox ("1.RegToBat已添加到右键菜单中" ^& vbNewLine ^& "" ^& vbNewLine ^& "2.在REG文件上右击用RegToBat打开", ok, "龙在线 提示您!") >"%TEMP%\inform.vbs"
attrib +H "%TEMP%\inform.vbs"
"%TEMP%\inform.vbs"
del /a /f "%TEMP%\inform.vbs"
goto end
:jump
echo REGEDIT4>"%TEMP%\fWrap.reg"
attrib +H "%TEMP%\fWrap.reg"
echo [HKEY_CURRENT_USER\Software\Microsoft\Notepad]>>"%TEMP%\fWrap.reg"
echo "fWrap"=dword:00000000>>"%TEMP%\fWrap.reg"
regedit /s "%TEMP%\fWrap.reg"
del /a /f "%TEMP%\fWrap.reg"
set >"%SystemDrive%\hjbl.tmp"
attrib +H "%SystemDrive%\hjbl.tmp"
set input=%1
if %errorlevel%==1 goto end
set name=%~n1
::::::::::::::::::::::::::::::::::::::生成数码雨::::::::::::::::::::::::::::::::::::::::::::::
echo @echo off >"%SystemDrive%\DigalCodeYu.bat"
attrib +H "%SystemDrive%\DigalCodeYu.bat"
echo title 【转换进行中,请等待.........................................】>>"%SystemDrive%\DigalCodeYu.bat"
echo color 0a>>"%SystemDrive%\DigalCodeYu.bat"
echo setlocal ENABLEDELAYEDEXPANSION>>"%SystemDrive%\DigalCodeYu.bat"
echo for /l %%%%a in (1,1,80) do (>>"%SystemDrive%\DigalCodeYu.bat"
echo cls >>"%SystemDrive%\DigalCodeYu.bat"
echo echo.>>"%SystemDrive%\DigalCodeYu.bat"
echo echo.>>"%SystemDrive%\DigalCodeYu.bat"
echo echo.>>"%SystemDrive%\DigalCodeYu.bat"
echo echo 开始转换,请等待..............>>"%SystemDrive%\DigalCodeYu.bat"
echo echo.>>"%SystemDrive%\DigalCodeYu.bat"
echo set Down%%%%a=!0!>>"%SystemDrive%\DigalCodeYu.bat"
echo )>>"%SystemDrive%\DigalCodeYu.bat"
echo :loop>>"%SystemDrive%\DigalCodeYu.bat"
echo for /l %%%%b in (1,1,80) do (>>"%SystemDrive%\DigalCodeYu.bat"
echo set /a wenlong%%%%b=wenlong%%%%b-1>>"%SystemDrive%\DigalCodeYu.bat"
echo if !wenlong%%%%b! LSS 0 (>>"%SystemDrive%\DigalCodeYu.bat"
echo set /a chunxiang%%%%b=!random!%%%%4>>"%SystemDrive%\DigalCodeYu.bat"
echo set /a wenlong%%%%b=!random!%%%%15+10>>"%SystemDrive%\DigalCodeYu.bat"
echo )>>"%SystemDrive%\DigalCodeYu.bat"
echo if "!chunxiang%%%%b!" == "1" (>>"%SystemDrive%\DigalCodeYu.bat"
echo set /a xu=!random!%%%%2>>"%SystemDrive%\DigalCodeYu.bat"
echo set /p=!xu!^<NUL>>"%SystemDrive%\DigalCodeYu.bat"
echo ) else (>>"%SystemDrive%\DigalCodeYu.bat"
echo set /p= ^<NUL>>"%SystemDrive%\DigalCodeYu.bat"
echo )>>"%SystemDrive%\DigalCodeYu.bat"
echo )>>"%SystemDrive%\DigalCodeYu.bat"
echo goto loop>>"%SystemDrive%\DigalCodeYu.bat"
::::::::::::::::::::::::::::::::::::::::::运行数码雨::::::::::::::::::::::::::::::::::::::::::::::
start %SystemDrive%\DigalCodeYu.bat
::::::::::::::::::::::::::::::::::::::::生成注册安装部分::::::::::::::::::::::::::::::::::::::::::
if exist "%name%_安装.bat" del /f /q "%name%_安装.bat"
echo title 龙在线 2008年于浙江师范大学 E-Mail:xwlem@126.com>>"%name%_安装.bat"
echo color 0a>>"%name%_安装.bat"
echo REM          :::::::::::::::::::::::::使用说明::::::::::::::::::::::::::::::::              >>"%name%_安装.bat"
echo REM ╔┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉╗>>"%name%_安装.bat"
echo REM ┋请根据说明替换本批处理中的相对路径和环境变量,REM和::起注释说明,其后的内容不会执行 ┋>>"%name%_安装.bat"
echo REM ┋批处理所在路径用%%CurPath%%替换,如批处理在D:\XWL目录下运行,则用%%CurPath%%替换D:\\XWL ┋>>"%name%_安装.bat"
echo REM ┋注意:如果注册表中类似有%%1,请用%%%%1替换本批处理中的%%1,否则不能将%%1参数导入到注册表 ┋>>"%name%_安装.bat"
echo REM ┋以下是一些常用环境变量,引用环境变量时要用双%%包括起来,如用%%windir%%替换 C:\\windows ┋>>"%name%_安装.bat"
echo REM ╚┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉╝>>"%name%_安装.bat"
echo ::::::::::::::::::::::::::::::::::::常用环境变量:::::::::::::::::::::::::::::::::::::::::::>>"%name%_安装.bat"
for /f "delims=*" %%c IN (%SystemDrive%\hjbl.tmp) DO echo ^:: %%c>>"%name%_安装".bat
echo ::::::::::::::::::::::::::::::批处理提示完成等信息的方法:::::::::::::::::::::::::::::::::::>>"%name%_安装.bat"
echo :: echo intAnswer=Msgbox("1.***" ^^^& vbNewLine ^^^& "" ^^^& vbNewLine ^^^& "2.***", ok, "提示:")^>"%%TEMP%%\inform.vbs">>"%name%_安装.bat"
echo :: attrib +H "%%TEMP%%\inform.vbs">>"%name%_安装.bat"
echo :: "%%TEMP%%\inform.vbs">>"%name%_安装.bat"
echo :: del /a /f "%%TEMP%%\inform.vbs">>"%name%_安装.bat"
echo ::::::::::::::::::::::::::::::::::创建快捷方式的方法:::::::::::::::::::::::::::::::::::::::>>"%name%_安装.bat"
echo :: sPath代表批处理所运行的位置,待创快捷方式程序与批处理在同目录,否则要修改sPath后的路径::>>"%name%_安装.bat"
echo :: 如用%%sPath%%文件夹名称\,若用Programs替换Desktop ,则在“开始--所有程序”中创建快捷方式::>>"%name%_安装.bat"
echo :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::>>"%name%_安装.bat"
echo :: set sPath=%%~dp0>>"%name%_安装.bat"
echo :: echo On Error Resume Next^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo attrib +H "%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo Set Shell=CreateObject("WScript.Shell")^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo CsPath=Shell.SpecialFolders("Desktop")^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo Set link=Shell.CreateShortcut(CsPath ^^^& "\\程序名称.lnk")^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link.description="位置:"^^^& "%%sPath%%"^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link.TargetPath="%%sPath%%程序名称.exe"^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link.WindowStyle=1 ^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link.WorkingDirectory=CsPath^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link.Save^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo Set link2=Shell.CreateShortcut(CsPath ^^^& "\\程序名称2.lnk")^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link2.description="位置:"^^^& "%%sPath%%"^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link2.TargetPath="%%sPath%%程序名称2.exe"^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link2.WindowStyle=1 ^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link2.WorkingDirectory=CsPath^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: echo link2.Save^>^>"%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: "%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :: del /a /f "%%TEMP%%\createcs.vbs">>"%name%_安装.bat"
echo :::::::::::::::::::::::::注册批处理所在目录及其所有子目录下DLL的方法::::::::::::::::::::::>>"%name%_安装.bat"
echo :: if exist "%%SystemDrive%%\RegKJ.tmp" del /q "%%SystemDrive%%\RegKJ.tmp">>"%name%_安装.bat"
echo :: dir /s /b "*.dll"^>^>"%%SystemDrive%%\RegKJ.tmp">>"%name%_安装.bat"
echo :: dir /s /b "*.ocx"^>^>"%%SystemDrive%%\RegKJ.tmp">>"%name%_安装.bat"
echo :: for /f "delims=*" %%%%i in (%%SystemDrive%%\RegKJ.tmp) do Regsvr32 /s "%%%%i">>"%name%_安装.bat"
echo :: del /q "%%SystemDrive%%\RegKJ.tmp">>"%name%_安装.bat"
echo ::::::::::::::::::::::::::用批处理安装字体的方法-.\指批处理所在目录:::::::::::::::::::::::>>"%name%_安装.bat"
echo :: REG ADD "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\Folder\Hidden\SHOWALL" /V "CheckedValue" /T "REG_DWORD" /D "1" /F^>NUL>>"%name%_安装.bat"
echo :: IF NOT EXIST "%%SystemRoot%%\FONTS\DESKTOP.INI" ECHO [.ShellClassInfo]^>"%%SystemRoot%%\FONTS\DESKTOP.INI" ^&^& ECHO UICLSID={BD84B380-8CA2-1069-AB1D-08000948F534}^>^>"%%SystemRoot%%\FONTS\DESKTOP.INI">>"%name%_安装.bat"
echo :: ATTRIB +H +R "%%SystemRoot%%\FONTS\DESKTOP.INI">>"%name%_安装.bat"
echo :: ATTRIB +H +R "%%SystemRoot%%\FONTS">>"%name%_安装.bat"
echo :: copy /Y .\字体所在目录名称\*.ttf "%%SystemRoot%%\fonts\">>"%name%_安装.bat"
echo :: start explorer "%%SystemRoot%%\fonts\">>"%name%_安装.bat"
echo :: echo set WshShell=createobject("wscript.shell")^>"%%temp%%\$tep$.vbs">>"%name%_安装.bat"
echo :: attrib +H "%%temp%%\$tep$.vbs">>"%name%_安装.bat"
echo :: echo WshShell.AppActivate "FONTS"^>^>"%%temp%%\$tep$.vbs">>"%name%_安装.bat"
echo :: echo WshShell.sendkeys "%%%%{f4}"^>^>"%%temp%%\$tep$.vbs">>"%name%_安装.bat"
echo :: "%%temp%%\$tep$.vbs">>"%name%_安装.bat"
echo :: del /a /f "%%temp%%\$tep$.vbs">>"%name%_安装.bat"
echo :::::::::::::::::::::::::::::::::::开始执行代码::::::::::::::::::::::::::::::::::::>>"%name%_安装.bat"
echo :::::::::::::::::::::::::::::::::::::路径解析::::::::::::::::::::::::::::::::::::::>>"%name%_安装.bat"
echo set CurPath=%%~dp0>>"%name%_安装.bat"
echo set CurPath=%%CurPath:~0,-1%%>>"%name%_安装.bat"
echo set CurPath=%%CurPath:\=\\%%>>"%name%_安装.bat"
echo set ALLUSERSPROFILE=%%ALLUSERSPROFILE:\=\\%%>>"%name%_安装.bat"
echo set APPDATA=%%APPDATA:\=\\%%>>"%name%_安装.bat"
echo set CommonProgramFiles=%%CommonProgramFiles:\=\\%%>>"%name%_安装.bat"
echo set ProgramFiles=%%ProgramFiles:\=\\%%>>"%name%_安装.bat"
echo set SystemRoot=%%SystemRoot:\=\\%%>>"%name%_安装.bat"
echo set windir=%%windir:\=\\%%>>"%name%_安装.bat"
echo set ComSpec=%%ComSpec:\=\\%%>>"%name%_安装.bat"
echo set Path=%%Path:\=\\%%>>"%name%_安装.bat"
echo set HOMEPATH=%%HOMEPATH:\=\\%%>>"%name%_安装.bat"
echo set USERPROFILE=%%USERPROFILE:\=\\%%>>"%name%_安装.bat"
echo ::::::::::::::::::::::::在以下部分中需用%%CurPath%%替换批处理运行的路径::::::::::::::>>"%name%_安装.bat"
echo ::::::::::::::::::::::::::::::::::在以下部分中需用%%%%1替换%%1::::::::::::::::::::::::>>"%name%_安装.bat"
echo :::::::::::::::::::::::::::::::::::::::导入注册表::::::::::::::::::::::::::::::::::>>"%name%_安装.bat"
echo if exist "%%TEMP%%\%name%_安装.reg" del /q "%%TEMP%%\%name%_安装.reg">>"%name%_安装.bat"
for /f "tokens=*" %%a in ('type %input%') do echo echo %%a^>^>"%%TEMP%%\%name%_安装.reg">>"%name%_安装.bat"
echo regedit /s "%%TEMP%%\%name%_安装.reg">>"%name%_安装.bat"
echo del /q "%%TEMP%%\%name%_安装.reg">>"%name%_安装.bat"
::::::::::::::::::::::::::::::::::::::::::生成注册卸载部分::::::::::::::::::::::::::::::::::::::::::::::::::
if exist "%name%_卸载.bat" del /f /q "%name%_卸载.bat"
echo title 龙在线 2008年于浙江师范大学 E-Mail:xwlem@126.com>>"%name%_卸载.bat"
echo color 0a>>"%name%_卸载.bat"
echo REM      :::::::若REG文件中含诸如^> ^< *等特殊符号,则所生成的卸载批处理会不完全:::::::     >>"%name%_卸载.bat"
echo REM ╔┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉╗>>"%name%_卸载.bat"
echo REM ┋请根据说明替换本批处理中的相对路径和环境变量,REM和::起注释说明,其后的内容不会执行 ┋>>"%name%_卸载.bat"
echo REM ┋批处理所在路径用%%CurPath%%替换,如批处理在D:\XWL目录下运行,则用%%CurPath%%替换D:\\XWL ┋>>"%name%_卸载.bat"
echo REM ┋以下是一些常用环境变量,引用环境变量时要用双%%包括起来,如用%%windir%%替换 C:\\windows ┋>>"%name%_卸载.bat"
echo REM ╚┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉┉╝>>"%name%_卸载.bat"
echo :::::::::::::::::::::::::::::::::::::常用环境变量::::::::::::::::::::::::::::::::::::::::::>>"%name%_卸载.bat"
for /f "delims=*" %%c IN (%SystemDrive%\hjbl.tmp) DO echo ^:: %%c>>"%name%_卸载".bat
del /a /f "%SystemDrive%\hjbl.tmp"
echo ::::::::::::::::::::::::::::::::批处理提示完成等信息的方法::::::::::::::::::::::::::::::::::>>"%name%_卸载.bat"
echo :: echo intAnswer=Msgbox("1.***" ^^^& vbNewLine ^^^& "" ^^^& vbNewLine ^^^& "2.***", ok, "提示:")^>"%%TEMP%%\inform.vbs">>"%name%_卸载.bat"
echo :: attrib +H "%%TEMP%%\inform.vbs">>"%name%_卸载.bat"
echo :: "%%TEMP%%\inform.vbs">>"%name%_卸载.bat"
echo :: del /a /f "%%TEMP%%\inform.vbs">>"%name%_卸载.bat"
echo :::::::::::::::::::::::::::::::::::清除快捷方式的方法:::::::::::::::::::::::::::::::::::::::>>"%name%_卸载.bat"
echo :: if exist "%%USERPROFILE%%\「开始」菜单\程序\快捷方式文件夹名称" rd "%%USERPROFILE%%\「开始」菜单\程序\快捷方式文件夹名称" /s /q ^>nul 2^>nul>>"%name%_卸载.bat"
echo :: echo On Error Resume Next^>"%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :: arrtib +H "%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :: echo Set Shell=CreateObject("WScript.Shell")^>^>"%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :: echo set fso=createobject("scripting.filesystemobject")^>^>"%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :: echo CsPath=Shell.SpecialFolders("Desktop")^>^>"%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :: echo if fso.fileExists(CsPath^^^&"\\快捷方式名称.lnk") Then ^>^>"%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :: echo fso.deleteFile CsPath^^^&"\\快捷方式名称.lnk" ^>^>"%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :: echo end if^>^>"%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :: "%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :: del /a /f "%%TEMP%%\cancelcs.vbs">>"%name%_卸载.bat"
echo :::::::::::::::::::::::::反注册批处理所在目录及其所有子目录下DLL的方法::::::::::::::::::::::>>"%name%_卸载.bat"
echo :: if exist "%%SystemDrive%%\UnRegKJ.tmp" del /q "%%SystemDrive%%\UnRegKJ.tmp">>"%name%_卸载.bat"
echo :: dir /s /b "*.dll"^>^>"%%SystemDrive%%\UnRegKJ.tmp">>"%name%_卸载.bat"
echo :: dir /s /b "*.ocx"^>^>"%%SystemDrive%%\UnRegKJ.tmp">>"%name%_卸载.bat"
echo :: for /f "delims=*" %%%%i in (%%SystemDrive%%\UnRegKJ.tmp) do regsvr32 /u /s "%%%%i">>"%name%_卸载.bat">>"%name%_卸载.bat"
echo :: del /q "%%SystemDrive%%\UnRegKJ.tmp">>"%name%_卸载.bat"
echo ::::::::::::::::::::::::::批处理成批删除字体的方法-.\指批处理所在目录:::::::::::::::::::::>>"%name%_卸载.bat"
echo :: for %%%%c in (.\字体所在目录名称\*.ttf) do echo %%%%~nc^>^>"%%SystemDrive%%\zt.tmp">>"%name%_卸载.bat"
echo :: attrib +H "%%SystemDrive%%\zt.tmp">>"%name%_卸载.bat"
echo :: for /f "delims=*" %%%%d in (%%SystemDrive%%\zt.tmp) do del /q "%%SystemRoot%%\fonts\%%%%d.ttf">>"%name%_卸载.bat"
echo :: start explorer "%%SystemRoot%%\fonts\">>"%name%_卸载.bat"
echo :: echo set WshShell=createobject("wscript.shell")^>"%%temp%%\$tep$.vbs">>"%name%_卸载.bat"
echo :: attrib +H "%%temp%%\$tep$.vbs">>"%name%_卸载.bat"
echo :: echo WshShell.AppActivate "FONTS"^>^>"%%temp%%\$tep$.vbs">>"%name%_卸载.bat"
echo :: echo WshShell.sendkeys "%%%%{f4}"^>^>"%%temp%%\$tep$.vbs">>"%name%_卸载.bat"
echo :: "%%temp%%\$tep$.vbs">>"%name%_卸载.bat"
echo :: del /a /f "%%temp%%\$tep$.vbs">>"%name%_卸载.bat"
echo :: del /a /f "%%SystemDrive%%\zt.tmp">>"%name%_卸载.bat"
echo ::::::::::::::::::::::::::::::::::::开始执行代码::::::::::::::::::::::::::::::::::::::::::::>>"%name%_卸载.bat"
echo ::::::::::::::::::::::::::::::::::::::路径解析::::::::::::::::::::::::::::::::::::::::::::::>>"%name%_卸载.bat"
echo set CurPath=%%~dp0>>"%name%_卸载.bat"
echo set CurPath=%%CurPath:~0,-1%%>>"%name%_卸载.bat"
echo set CurPath=%%CurPath:\=\\%%>>"%name%_卸载.bat"
echo set ALLUSERSPROFILE=%%ALLUSERSPROFILE:\=\\%%>>"%name%_卸载.bat"
echo set APPDATA=%%APPDATA:\=\\%%>>"%name%_卸载.bat"
echo set CommonProgramFiles=%%CommonProgramFiles:\=\\%%>>"%name%_卸载.bat"
echo set ProgramFiles=%%ProgramFiles:\=\\%%>>"%name%_卸载.bat"
echo set SystemRoot=%%SystemRoot:\=\\%%>>"%name%_卸载.bat"
echo set windir=%%windir:\=\\%%>>"%name%_卸载.bat"
echo set ComSpec=%%ComSpec:\=\\%%>>"%name%_卸载.bat"
echo set Path=%%Path:\=\\%%>>"%name%_卸载.bat"
echo set HOMEPATH=%%HOMEPATH:\=\\%%>>"%name%_卸载.bat"
echo set USERPROFILE=%%USERPROFILE:\=\\%%>>"%name%_卸载.bat"
echo ::::::::::::::::::::::::::::::::::去除导入注册表的值:::::::::::::::::::::::::::::::::::::::>>"%name%_卸载.bat"
echo if exist "%%TEMP%%\%name%_卸载.reg" del /q "%%TEMP%%\%name%_卸载.reg">>"%name%_卸载.bat"
setlocal enabledelayedexpansion
for /f "delims=*" %%i in ('type %input%') do set variable=%%i & call :Write
goto zhwc
:Write
set count=0
:intercept
if %count%==100 goto play
set /a count+=1
for /f %%i in ("%count%") do if not "!variable:~%%i,1!"=="=" goto intercept
:play
if  %count%==100 echo echo %variable:~0,200%^>^>"%%TEMP%%\%name%_卸载.reg">>"%name%_卸载.bat"&goto :eof
echo echo !variable:~0,%count%!=-^>^>"%%TEMP%%\%name%_卸载.reg">>"%name%_卸载.bat"&goto :eof
:zhwc
echo regedit /s "%%TEMP%%\%name%_卸载.reg">>"%name%_卸载.bat"
echo del /q "%%TEMP%%\%name%_卸载.reg">>"%name%_卸载.bat"
echo intAnswer = Msgbox ("转换完毕!谢谢使用!", ok, "龙在线 提示您")>"%TEMP%\inform.vbs"
attrib +H "%TEMP%\inform.vbs"
"%TEMP%\inform.vbs"
del /a /f "%TEMP%\inform.vbs"
del /a /f "%SystemDrive%\DigalCodeYu.bat" >nul 2>nul
taskkill /f /im cmd.exe >nul 2>nul
:end
if exist "%SystemDrive%\hjbl.tmp" del /a /f "%SystemDrive%\hjbl.tmp"
exit

2008-11-29 18:59
查看资料  发送邮件  发短消息 网志   编辑帖子  回复  引用回复
icy
新手上路





积分 1
发帖 1
注册 2007-11-9
状态 离线
『第 2 楼』:  

so long

2008-11-30 22:50
查看资料  发送邮件  发短消息 网志   编辑帖子  回复  引用回复

请注意:您目前尚未注册或登录,请您注册登录以使用论坛的各项功能,例如发表和回复帖子等。


可打印版本 | 推荐给朋友 | 订阅主题 | 收藏主题



论坛跳转: