回复 8# nevergiveup520 - del /q "%userprofile%\「开始」菜单\注销.lnk"
-
- rem 创建exe文件的lnk快捷方式
- ::指定路径和名称
- set "LnkFile=%userprofile%\「开始」菜单\注销.lnk"
- ::指定主程序
- set "TargetPath=%SystemRoot%\system32\logoff.exe"
- ::指定起始位置
- set "WorkingDirectory=%SystemRoot%\system32"
- ::指定快捷键
- set "Hotkey=Ctrl+Shift+L"
- ::指定图标
- set "IconLocation=%windir%\system32\shell32.dll,44"
-
- del "%LnkFile%" /f /q >nul 2>nul
-
- call :CreateShort "%LnkFile%" "%TargetPath%" "%WorkingDirectory%" "%HotKey%" "%IconLocation%"
-
- ::Arguments 目标程序参数
- ::Description 快捷方式备注
- ::FullName 返回快捷方式完整路径
- ::Hotkey 快捷方式快捷键
- ::IconLocation 快捷方式图标,不设则使用默认图标
- ::TargetPath 目标
- ::WindowStyle 窗口启动状态
- ::WorkingDirectory 起始位置
- :CreateShort
- mshta VBScript:Execute("Set a=CreateObject(""WScript.Shell""):Set b=a.CreateShortcut(""%~1""):b.TargetPath=""%~2"":b.WorkingDirectory=""%~3"":b.HotKey=""%~4"":b.IconLocation=""%~5"":b.Save:close")
复制代码
|