ENDFUNCTION        End function declaration

<< Click to Display Table of Contents >>

Navigation:  Robo-FTP User's Guide > Script Programming > Script Commands > All Script Commands >

ENDFUNCTION        End function declaration

Syntax:

ENDFUNCTION

 

Arguments:

None

 

Options:

None

 

 

 

This script directive is used to mark the end a function declaration in the same way that the FUNCTION command marks the beginning of a function declaration. Each function declaration must have only one beginning and one ending.

 

You may define multiple functions in the function declaration section between the BEGINFUNCTIONS and ENDFUNCTIONS commands but the individual function declarations must not be nested.

 

Here is a simple example of a function declaration section containing two function declarations:

 

BEGINFUNCTIONS

FUNCTION MyFunction

 ;; body of MyFunction

 RETURN

ENDFUNCTION

FUNCTION YourFunction

 ;; body of YourFunction

 RETURN

ENDFUNCTION

ENDFUNCTIONS

 

Those functions declared above don't actually DO anything. The purpose of this example is merely to show how to begin and end a function definition within a function declaration section.

 

 

Related command(s): BEGINFUNCTIONS, ENDFUNCTIONS, FUNCTION, RETURN

See also: Using Functions