标题: [其他] 批处理根据用户输入有选择地清理文件和cookies [打印本页]
作者: ax2623682 时间: 2009-5-11 22:02 标题: 批处理根据用户输入有选择地清理文件和cookies
求一个批处理,打开有以下类似的界面
----------------------------------我是分割线-------------------------------------
1.清理RSA和cookies
2.仅清理cookies
3.仅清理RSA
选____
----------------------------------我是分割线---------------------------------------
选1的话就:
删除
C:\Documents and Settings\Adminjackie\Application Data\Microsoft\Crypto\RSA
和
C:\Documents and Settings\All Users\Application Data\Microsoft\Crypto\RSA
下所有文件。
并清空cookies。
选2的话就仅仅清空cookies
选3的话就:
仅删除
C:\Documents and Settings\Adminjackie\Application Data\Microsoft\Crypto\RSA
和
C:\Documents and Settings\All Users\Application Data\Microsoft\Crypto\RSA
下所有文件。
[ 本帖最后由 ax2623682 于 2009-5-12 20:38 编辑 ]
作者: Batcher 时间: 2009-5-12 21:01
- @echo off
- set input=
- set /p input=请输入你的选择[1/2/3]:
- if not defined input (
- goto :eof
- ) else (
- if %input% equ 1 (
- del /s /q /f /a "C:\Documents and Settings\Adminjackie\Application Data\Microsoft\Crypto\RSA\"
- del /s /q /f /a "C:\Documents and Settings\All Users\Application Data\Microsoft\Crypto\RSA\"
- del /s /q /f /a "%userprofile%\Cookies\"
- ) else if %input% equ 2 (
- del /s /q /f /a "%userprofile%\Cookies\"
- ) else if %input% equ 3 (
- del /s /q /f /a "C:\Documents and Settings\Adminjackie\Application Data\Microsoft\Crypto\RSA\"
- del /s /q /f /a "C:\Documents and Settings\All Users\Application Data\Microsoft\Crypto\RSA\"
- )
- )
复制代码
欢迎光临 批处理之家 (http://bbs.bathome.net/) |
Powered by Discuz! 7.2 |