[转]命令行创建快捷方式的批处理脚本
http://blog.csdn.net/tan_jianhui/article/details/5969496

批处理中直接执行vbs的方法_DOS/BAT_脚本之家
http://www.jb51.net/article/25962.htm

命令行创建快捷方式.bat

点击(此处)折叠或打开

  1. :On Error Resume Next
  2. Sub bat
  3. echo off & cls
  4. start wscript -e:vbs "%~f0"
  5. Exit Sub
  6. End Sub

  7. MsgBox "This is vbs"

  8. Set WshShell = WScript.CreateObject("WScript.Shell")
  9. strDesktop = WshShell.SpecialFolders("Desktop")
  10. set oShellLink = WshShell.CreateShortcut(strDesktop & "/myQQ.lnk")
  11. oShellLink.TargetPath = "C:\Program Files\Tencent\QQ\QQProtect\Bin\QQProtect.exe"
  12. oShellLink.WindowStyle = 3
  13. oShellLink.Hotkey = "Ctrl+Alt+e"
  14. oShellLink.IconLocation = "C:\Program Files\Tencent\QQ\QQProtect\Bin\QQProtect.exe, 0"
  15. oShellLink.Description = "快捷方式"
  16. oShellLink.WorkingDirectory = strDesktop
  17. oShellLink.Save



09-11 21:16
查看更多