A Method procedure is a series of ViviFire statements enclosed by Method and End Method clauses.
The Method procedure performs a task, then returns control to the calling code (known as the "caller"). When it returns, the procedure returns a value to the caller.
Each time the procedure is called, its statements are executed, beginning with the first executable statement after the Method clause. Execution normally proceeds until it encounters the End Method clause; however, it can be halted by either an Exit Method or Return statement.
You can define a Method procedure in modules, classes, objects, and traits. It is public, meaning that it can be called from any other code.
A Method procedure can take arguments, such as constants, variables, or expressions, which are passed to it by the caller.
The syntax for a usual Method procedure is the following:
[ modifier ] Method methodName [ parameterList ] ' statements End Method
The modifier can specify information about abstraction and overriding. For more information see Method Statement.
You define the parameter list much like you would for Sub Procedures.