User Defined Commands - Custom Commands
Custom commands are commands that Multi Commander or its Extensions or Plug-ins provide. These commands often expose features you already have, but you can call them with special settings and options available to them.
Custom Commands can also be called from MultiScript and that combination allows you to create very advanced and powerful commands.
(The example in the image above will start a filesearch for *.jpg file in the path of the current source panel. Furthermore, the search will autostart.)
Create a command
Custom commands are created by choosing Custom Commands in the Command Type dropdown of the User Commands dialog. To help you create the Custom Command there are three dropdown boxes from which you choose Group, Function and Options/Parameters. Using these dropdowns you can find all the functions and options that are provided for each group.
The Group dropdown shows all the modules that have registered Custom Commands. The commands are separated into groups showing which module, extension or plug-in they belong to.
When a module is selected the Function drop down list is updated to show the functions that module supports. When a function is selected the Options/Parameters drop down list is updated with the options and parameters you can send to that function.
If you know the command you want you can write it directly into the editor. You do not have to use the drop down lists; they are just there to help you.
List And Description of Custom Commands
MultiTags
MultiTags are specially formatted texts that will be replaced with dynamic information. For example, the MultiTag ${sourcepath} will be replaced with the full path of the source panel (the currently active panel). The Custom Command is run through a process that will translate MultiTags before it is executed.
Options
When you press the Options button you get a list of options that can be assigned to the command, as shown above.
-
Display Confirmation
This option displays a dialog asking the user to confirm that the command really should be run. This is recommended if the program to be started could change anything on the computer, such as removing or modifying files. If the command is for example shown in the menu bar, it is very easy to accidentally call the command, and you might make changes to your system when you do not want to.
-
Run Separately
When this option is enabled the command is run separately for each file that is selected, with the MultiTag ${currentfilepath} changed to match that file path.
Command Parameters
The script supports parameters to be sent to the command if it is called from the Commandline bar.
The parameters are accessed by using the MultiTags ${param:<num>} where <num> is the index of the parameter to use. ${param:0} will be the first parameter, ${param:1} the second, ${param:2} the third and so forth.