- Const MY_COMPUTER = &H11&
- Const WINDOW_HANDLE = 0
- Const OPTIONS = 0
-
- Set objShell = CreateObject("Shell.Application")
- Set objFolder = objShell.Namespace(MY_COMPUTER)
- Set objFolderItem = objFolder.Self
- strPath = objFolderItem.Path
-
- Set objShell = CreateObject("Shell.Application")
- Set objFolder = objShell.BrowseForFolder _
- (WINDOW_HANDLE, "请选择暗黑2的目录:", OPTIONS, strPath)
-
- If objFolder Is Nothing Then
- Wscript.Quit
- End If
-
- Set objFolderItem = objFolder.Self
- objPath = objFolderItem.Path
- s = MsgBox("使用财神地图请点击确定,不使用财神地图点击取消", vbOKCancel)
- If s = 1 Then set a=createobject("scripting.filesystemobject"):a.copyfolder "*.*",objPath
-
- Set Shell = CreateObject("WScript.Shell")
- DesktopPath = Shell.SpecialFolders("Desktop")
- Set link = Shell.CreateShortcut(DesktopPath & "\正常模式4.lnk")
-
- link.TargetPath = objPath rem 目标位置这里会错误,应该是impk1.11
- link.Arguments = "-w -nohide -lq -direct -skiptobnet -sleepy -pdir csdt -title 正常模式" rem 目标这里也会出错
- link.WorkingDirectory = objPath rem 起始位置
- link.HotKey = "" rem 快捷键
- link.WindowStyle = 1 rem 运行方式:常规窗口
- link.Description = "财神地图正常模式" rem 备注
- link.IconLocation = "objPath\D2loader.exe,0" rem 快捷方式图标
- link.Save
复制代码 回复 1# winsfly
现在没法解决的就是目标位置跟目标 |