11

Is there an easy way in windows to set a given string, like "sidb" to run a program or open a given folder in Windows?

My original idea was to be able to run commands like that in the "Execute" start button menu (or Win + R),so I'd just have to do WIN+R and type "sidb".

What is the best way to accomplish this?

EDIT: May I rephrase this as : Is there a way to define for example, in systems variables, sibd="C:.......blabla\ and then I'd just have to type "sibd" in Run?

10 Answers10

17

You can make small batch files which execute the program, and name them after the desired alias. Then simply put them into a folder that's in your path environment variable.

example, ff.cmd:

@echo off
"C:\Program Files\Mozilla Firefox\Firefox.exe"
9

Surprised on one has mentioned this one

http://weblogs.asp.net/whaggard/archive/2004/04/11/111232.aspx

It concerns adding registry keys under HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths Which is evaluated just after %PATH%

Take note that the reg sub key name would be what you want to type + .exe

so add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\sibd.exe with a default value of C:.......blabla\

it seems much easier(and in some ways safer, others not so much) to granularly manage than the horrendous %PATH% string.

Maslow
  • 936
7

If all you want to do is run program or open folders, you can make a batch file to do that. As long as that batch file is in the PATH (and doesn't conflict in name) it will be run by any command prompt.

notepad example:
make a batch file to open notepad called np.bat In the batch file write
START %windir%\system32\notepad.exe

C drive example:
make a batch file to open the c drive called c.bat In the batch file write
START explorer C:\

There are also third party apps: SlickRun, MagicWords, Launchy, slimKEYS, Enso Launcher, Colibri

3

You can use a free program launcher.

See this article for a discussion of some the best : Best Free Program Launcher, which contains info about Launchy, Find and Run Robot, Enso, Slickrun, FSL Launcher, Fast Launcher, 8Start, and more.

harrymc
  • 498,455
1

I use a path, C:\bin, which I put into the system PATH variable. I put things like GNU utils, SysInternals, and shortcuts to frequently used programs here. For example, a short to notepad++ called np. Winkey+R, np, enter. Done.

Dave
  • 161
  • 4
1

I wonder why nobody mentioned MKLINK. It's available in Vista and 7 and allows to make symlinks for files AND folders.

Syntax:

mklink "c:\SymlinkFile" "c:\windows\realFile"

Easy.

sinni800
  • 3,169
1

You could use Colibri - Leet Speak, although it's not being updated any more, the source from GitHub.

The starting configuration isn't great, but if you edit the SQLLite databases and change it to a single path you can drop links, files, batches there and execute them by simply pressing Ctrl+Space, then typing in some of the characters of it's name.

e.g. start Firefox: Ctrl+Space type in ff enter

It also allows to add arguments by pressing tab and then enter them, e.g. type in ipconfig /all

Takes some work to set it up though.

wonea
  • 1,877
Zenir
  • 11
0

Have you considered a program like slickrun? It is very lightweight and useful; allowing you to map key strokes to commands as well as setting up short aliases for commands.

I would highly recommend it for the type of usage you're describing. There are other alternatives that do similar things, but it looks like maintenance and improvements to slickrun are now being done by the fine folks who brought us fiddler2.

Alternatives can be found at alternativeto.net, and elsewhere using google.

John Weldon
  • 1,709
0

The fastest way I think you could run programs is either by hotkey or by just typing it.

For hotkey purposes, you have Qliner Hotkeys.

For just typing it without pressing any prior/subsequent key, you have PhaseExpress.

Examples of PhaseExpress:

Visit SuperUser? runSU. Play StarCraft II? runSC2.

I add run because it doesn't interfere when typing SU here or SC2 on Gaming websites or in-game, but it's fully customizable and you can also choose to launch only by pressing a subsequent key. It also allows you to do text substitution, which can speed up things a lot...

Link to PhaseExpress? linkPE types [PhaseExpress](http://www.phraseexpress.com/).

0

Made an simple CLI Framework for this. http://code.google.com/p/syswin32/downloads/list

Based on sqlite, give it a try.

patricks
  • 636