Script Language Overview

Reference:        Programming a Script

                        Editing a Script

                        Alphabetical Command List 

                        Topical Command List 

The scripting language is composed of keywords that allow you to program the operation of Beyond FTP.  These are grouped into several categories:

1.   Global Commands.  These commands apply to the operation of the entire script.  They control repetition, restarting, transfer limits, and several other aspects of the script.

2.   File and Transfer Commands.  These commands perform the file actions associated with the script.  They also include the modifiers that provide control over these actions.  File actions can include wildcard characters.

3.   Program Execution Commands.  These commands execute programs.  They include the specialized Alert command for sending email as well as the Run command for any third party software.

4.   Flow Control Commands.  These commands are used to make decisions about which script statements will be processed or repeated.  There is a single looping command (While) and a single decision command (If).  These are supported by a number of commands that allow you stop the script, break out of a loop, and wait for actions to complete.

5.   Error Handling Commands.  These commands control the handling of individual errors and whether actions are to be retried.

The reference material discusses each command in detail.  All commands must occur on separate lines.  Certain keywords, such as From and To must occur in pairs.  These are treated as a single command for the purposes of the documentation.  Spaces and tabs are generally ignored.  The exception to this rule occurs with file names, where spaces are treated as part of the name.

The syntax of each command is presented according to the following rules (Backus Naur Form):

•      Terminal characters or words are Bold.  These are included in the command exactly as they appear, except that case is ignored.

•      Single terminal characters, or strings of symbols (for example, “<=”) are included with double-quotes.  Only the character(s) within the quotes would be included in the command.

•      Non-terminals (those things that have further definitions) are simply English descriptions where the words are connected with an underline character.  For example, Boolean_expression.  These will always include a hypertext link to the definition.

•      Non-terminal definitions are specified following the ::=.  This can be read “is defined as”.

•      Optional portions are presented within square brackets [ ].  The square brackets are NOT part of the command.  They would be omitted when entering the command.

•      Choices are separated by a vertical bar |, indicating that one or the other choice must be made.

•      Choices within a command are grouped within parentheses ( ).  These are omitted if the entire definition would be enclosed.

•      Repetition within a command is indicated using braces { }.  Items within braces may be repeated 0 or more times.

Consider the following definitions:

            digit ::= “0” | “1” | “2”  | “3” | “4” | “5” | “6” | “7” || “9”
           
numeric_literal ::= [ “-“ ] digit { digit }
            string_literal ::= “”” { any_character } “””
           
boolean_literal ::= true | false
           
numeric_value ::= numeric_literal | numeric_variable

The entire language is built up in this way.  Note that a numeric literal may start with a minus sign, then must consist of at least one digit, followed by 0 or more digits.  A string_literal begins and ends with double-quotes and may include zero or more characters between the quotes. 

The syntax, with examples, is presented in a separate window, where hyper-links do not change the contents of the main documentation window.  The semantics of each command are still discussed in the main documentation.

The best way to learn how the commands are structured is to generate the commands using one of the methods in Programming a Script