User-defined command: Difference between revisions
(Rewritten page) |
(Improved the description of user-defined commands.) |
||
Line 1: | Line 1: | ||
'''User-defined commands''' are commands | '''User-defined commands''' are commands that can be created by the user in addition to the built-in [[internal command]]s of [[Total Commander]]. These commands can either start an external program with desired parameters, or execute a comma separated list of internal commands. | ||
User-defined commands have the em_ prefix (which stands for extended command) to make them easy distinguishable from the built-in internal commands which generally have the cm_ prefix. | User-defined commands have the em_ prefix (which stands for extended command) to make them easy distinguishable from the built-in internal commands which generally have the cm_ prefix. |
Latest revision as of 13:36, 23 June 2024
User-defined commands are commands that can be created by the user in addition to the built-in internal commands of Total Commander. These commands can either start an external program with desired parameters, or execute a comma separated list of internal commands.
User-defined commands have the em_ prefix (which stands for extended command) to make them easy distinguishable from the built-in internal commands which generally have the cm_ prefix.
Use the Command browser to define and manage the user-defined commands.
Usage cases
Cases where user-defined commands are useful are:
- A user-defined command can be used as a shorthand name for a program or command with desired parameters.
- By creating a user-defined command for an external program, you can include the command to be executed in a list of commands.
- Sometimes executing a command with parameters does not work when executing a list of commands, for example when doing this on Total Commander's command line. In that case you can create a user-defined command (without parameters) which executes the command with paramaters, so it can be executed in the list of commands.
Examples
Execute an external program
This example demonstrates a user-defined command that executes an external program.
The user-defined command em_qsp
is defined as:
Command: %COMMANDER_PATH%\Addons\TC Quick Search Plus\TCQSP.exe Parameters: %P Icon file: %COMMANDER_PATH%\Addons\TC Quick Search Plus\TCQSP.exe Tooltip: Quick filter
Execute an internal command with parameters
This example demonstrates a user-defined command that executes an internal command with a parameter.
The user-defined command em_myproject
is defined as:
Command: OPENTABS %appdata%\Total Commander\Tabs\My Project.tab Tooltip: My Project