What is the list of special variables available when writing a shell command for a context menu

Posted by giovanni.pellicciotta on Super User See other posts from Super User or by giovanni.pellicciotta
Published on 2010-05-02T07:05:59Z Indexed on 2010/05/02 7:08 UTC
Read the original article Hit count: 363

When extending the Windows' shell context menu (e.g. for adding an 'Open command here' prompt on directories), a 'command' key needs to be created in the registry.

The value of this 'command' key apparently can be any valid command line.

I want to know which 'special variables' are available for use inside this command line.

For example, I use following command for opening and cmd window from within a directory's context menu (*):

cmd.exe /e:on /f:on /s /k pushd "%V"

I cannot find any reference to what %V actually means or what the full list of such variables is.


(*) Following registry keys are created for this: [HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Directory\shell\cmdshell] @=Open Command Prompt Here"

HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Directory\shell\cmdshell\command] @="cmd.exe /e:on /f:on /s /k pushd \"%V\""

© Super User or respective owner

Related posts about windows-7

Related posts about Windows