shortcut

Create a shortcut with parameters added to the program path

纵然是瞬间 提交于 2020-01-11 10:43:49
问题 Here's the code, it works if I right click on the new .Lnk and remove the quotes from "C:\Windows\System32\control.exe /name Microsoft.Windowsupdate" to C:\Windows\System32\control.exe /name Microsoft.Windowsupdate echo off Cls set SCRIPT="%TEMP%\%RANDOM%-%RANDOM%-%RANDOM%-%RANDOM%.vbs" echo Set oWS = WScript.CreateObject("WScript.Shell") >> %SCRIPT% echo sLinkFile = "%USERPROFILE%\Desktop\Weekly Maintenance\Windows Update.lnk" >> %SCRIPT% echo Set oLink = oWS.CreateShortcut(sLinkFile) >>

Create a shortcut with parameters added to the program path

柔情痞子 提交于 2020-01-11 10:42:10
问题 Here's the code, it works if I right click on the new .Lnk and remove the quotes from "C:\Windows\System32\control.exe /name Microsoft.Windowsupdate" to C:\Windows\System32\control.exe /name Microsoft.Windowsupdate echo off Cls set SCRIPT="%TEMP%\%RANDOM%-%RANDOM%-%RANDOM%-%RANDOM%.vbs" echo Set oWS = WScript.CreateObject("WScript.Shell") >> %SCRIPT% echo sLinkFile = "%USERPROFILE%\Desktop\Weekly Maintenance\Windows Update.lnk" >> %SCRIPT% echo Set oLink = oWS.CreateShortcut(sLinkFile) >>

Excel VBA to list key bindings (OnKey ?)

你。 提交于 2020-01-11 05:11:35
问题 I am working with a large set of Excel vba scripts and some of them are bound to Ctrl-key combinations. I know how to set one at a time in the user interface for Excel: Pull up the list of vba scripts (Alt-F8), select a script, and click Options. Then you can bind/unbind the script to a Ctrl-key combo. However, you can bind more than one script to the same key, and Excel will pick one (probably the first one it finds in some manner) and ignore the other bindings. So, I want to assign Ctrl-e

How can I use JScript to create a shortcut that uses “Run as Administrator”

风流意气都作罢 提交于 2020-01-09 10:44:07
问题 I have a JScript script that runs using cscript.exe . It creates a shortcut on the desktop (and in the start menu) that runs cscript.exe with parameters to run another JScript script. It looks, in relevant part, like this: function create_shortcut_at(folder, target_script_folder) { var shell = new ActiveXObject("WScript.Shell"); var shortcut = shell.CreateShortcut(folder + "\\Run The Script.lnk"); shortcut.TargetPath = "cscript"; shortcut.Arguments = "\""+target_script_folder+"\\script.js\"

How to create a shortcut using PowerShell

微笑、不失礼 提交于 2020-01-08 17:06:25
问题 I want to create a shortcut with PowerShell for this executable: C:\Program Files (x86)\ColorPix\ColorPix.exe How can this be done? 回答1: I don't know any native cmdlet in powershell but you can use com object instead: $WshShell = New-Object -comObject WScript.Shell $Shortcut = $WshShell.CreateShortcut("$Home\Desktop\ColorPix.lnk") $Shortcut.TargetPath = "C:\Program Files (x86)\ColorPix\ColorPix.exe" $Shortcut.Save() you can create a powershell script save as set-shortcut.ps1 in your $pwd

pycharm step over shortcut on Mac

元气小坏坏 提交于 2020-01-07 01:50:23
问题 I'm on Mac with Pycharm. During debug, when I press F8 for step over shortcut, I actually triggers iTunes because F8 is for play/Stop music by default. Any idea what shortkey I can use for step over? 回答1: mmm, 2 options, you can go to settings in mac and go to keybpard, unchek use F1, F2 ,etc, as standar functions keys the another options is that sometimes you can press FN key and then the F8 key, and see what happens... 来源: https://stackoverflow.com/questions/38690874/pycharm-step-over

Quick Access and Namespace Extensions: Unpin object

谁说胖子不能爱 提交于 2020-01-06 05:58:11
问题 When I right click on an lnk file - link on a virtual folder in a namespace extension -, then the functions CreateViewObject and/or GetUiObjectOf of my IShellFolder/IShellFolder2 implementations are called. These functions are called with the IID_IContextMenu as parameter (riid) . Also when QueryContextMenu is called the flag CMF_VERBSONLY (0x00000002) is set. It means that 1) I know that a menu should be shown and 2) that because of the flag CMF_VERBSONLY that this menu was queried by a .lnk

C# ShortCut Path Modification

我只是一个虾纸丫 提交于 2020-01-03 15:33:25
问题 I've created a program which generates a shortcut to a specific EXE selected via the open file dialog, using some library. I got it to work but I want the program to add a parameter to the Target path to make it look like this: ( "E:\Cod4\iw3mp.exe" +Seta Map mp_crash ). What can I do to add the ( + Seta Map mp_Crash ) part after the " mark without removing it or ruining the extension of the .exe? Here is block of the code I wrote to add the parameter: label1.Text = openFileDialog1.FileName;

vbs script to change shortcuts working in 7 but not in XP

允我心安 提交于 2020-01-03 05:12:06
问题 I'm trying to write a script that will update desktop shortcuts in WinXP and Win7 (32 and 64bit). I'm having 2 problems, in XP, the target path of the shortcut won't change, and in both XP and 7, the "Start In" part of the shortcut won't change. Whats wrong here and how can I correct? If InStr(GetWindowsVer(), "XP") > 0 then IterateFolder("C:\Documents and Settings\") Elseif InStr(GetWindowsVer(), "7") > 0 then IterateFolder("C:\Users\") End if Sub IterateFolder(folderPath) Dim

firefox add-on shortcut does not work anymore

送分小仙女□ 提交于 2020-01-03 02:59:06
问题 I have used following commands in my browser.xul to set a shortcut for my addon. <keyset id="mainKeyset"> <key id="key_convert" modifiers="accel" keycode="VK_F12" oncommand="myfunction()" />" </keyset> It used to work for previous versions of Firefox, but not anymore for newer versions. has anything changed in the syntax? Thanks 回答1: That code example looks correct, I suspect that there is some code within myfunction() that is failing, so we need more information probably. Try to replace