Edit Commands dialog

FlashFXP

Navigation: Main Window > Dialogs >

Send comments on this topic.
 

 

Edit Commands dialog

 

Custom commands allow the user to define saved custom (raw) commands.
Note that this does not constitute scripting.

 

  Command
Enter in the exact command, including any command tokens.

 

  Shortcut Key

Assigns a shortcut that executes the command. The shortcut is a combination of modifier keys and a character. To enter a shortcut, hold down the modifier keys and press a character. Valid modifiers include: CTRL, ALT, CTRL+ALT, CTRL+SHIFT, ALT+SHIFT, CTRL+SHIFT+ALT

 

Command Tokens: 

%f

The name of the selected item, this can be a file or a folder name.

%o

Selected Owner of file

%g

Selected Group of file

%p

Current Path

%c

Clipboard content

%d[caption]

Prompt for text. you can use \n to split long text into multiple lines, and \] to escape ] within the caption text.

%d["caption"]

Prompt for text. By quoting the caption you can use ] without having to escape it.

%[number]

Returns value of the Nth %d prompt

%b[caption]

Matches bookmark caption and replaces it with bookmark path


Scripted Commands: 

Delay [seconds]

A delay before continuing to the next command

List <parameters>

Refreshes the file list. the parameters are optional.

Compare

Compare folders

&window <title>

Creates a text window with the results of the commands that follow. The title is optional.

&list <parameters>

Refreshes the listing and adds the raw list format to an existing &window.

&cd <path>

Changes directory

&switch

Switches sides before continuing script

{ .. }

Command group. Some commands must be executed in pairs, i.e. RNFR/RNTO

An example is provided below.

$lowercase()

Change upper case characters in a string to lower case.

$uppercase()

Change lower case characters in a string to upper case.

$uplowcase()

Change the first character in a string to upper case and remaining characters to lower case.

 

Advanced Scripted Commands:

$replace("<string>","<substring>","<newstring>")

Replaces any occurrence of substring in string with newstring.

$replace("<string>","<substring>","<newstring>",1)

The additional switch at the end indicates that case-sensitive matching is performed, otherwise the default non-case-sensitive is used.


 

Examples

 

Rename the selected items by adding .bak to the end of each name.

{
RNFR %f
RNTO %f.bak
}

 

Here we use the rename command to convert the selected item names from mixed case to lowercase.

{

RNFR %f

RNTO $lowercase(%f)

}

 

Lets say there are bunch of files and the first part of the name is "RW1F-K5963170-" but it they all need to be renamed to start with "K5963170-RW1F-", again using the rename command but this time along with the $replace command.

{

RNFR %f

RNTO $replace("%f","RW1F-K5963170-","K5963170-RW1F-")

}

 

Send a site message.

SITE MSG %d[Please enter a message]

 

Last modified: Saturday, June 15, 2013

Copyright © 2010-2013 OpenSight Software, LLC