we get signal

2007-01-08

That Windows Run Dialog Box and quick program launching

(tags Windows XP, keyboard, command-line, environment variable)

I've been clearing my backlog of RSS feeds. I haven't read LifeHacker since 2006/07. Ugh. But there are gems almost every other post. I figured out some new things about the Windows Run dialog box from "Quick launch apps from the Run box" (2006/07/28). But let me list all the things that I know as well:

  • The Run dialog box is brought up by Windows+R.
  • You can run many programs just by typing the name and hitting Enter. Here let me show off my esoteric memorization skills:
    • cmd : Command Window
    • iexplore : Internet Explorer
    • explorer : Window Explorer (but you should just press Windows+R)
    • appwiz.cpl : Add or Remove Programs Control Panel
    • compmgmt.msc : Computer Management Snap In
    • services.msc : Services Snap In (but you could use net query or sc at the command line)
    • mstsc : Remote Desktop Client
    • gpedit.msc : Group Policy Editor Snap In
    • lusrmgr.msc : Local Users and Groups Snap In
    • a million more but I can't remember them
  • You can drag a file from an Explorer window and the pathname will be inserted into the dialog.
  • It searches the "Path" environment variable (System and User combined).

Here's where it gets interesting. If you craft your Path Environment variable just right, you can add your own programs. Let's enumerate the mechanism:

  • The System Environment Variable "Path" can accept references to other variables (eg. %SYSINTERNALS%) as long as they are System Environment Variables. Likewise, the same goes for User Environment Variable "Path". However, you cannot mix and match System and User variables.
  • The User Environment Variable "Path" is added after the System Environment Variable "Path".
  • Your fun keyboard apps that intercept and proxy actions like WinKey (defunct), HotKeyPlus, Mado Tsukai no Yuuutsuu do not pick up Environment Variable changes, and they need to be restarted. But of course, Windows Explorer does. Why!?
  • You can create a folder (C:\my shortcuts), stick that in your Path, and places shortcuts of program files in there to run them directly. (This is the LifeHacker nugget) Just make sure your "PATHEXT" System Environment Variable has ".lnk" in there.

Now to put interesting programs in the path. dd, md5deep, nemesis, putty, sqlite, SysInternals, etc.