- Special cases
- Named parameters
- Calling a global WLanguage browser procedure from a global Javascript procedure (found in the same set of procedures)
Calling a procedure/a function In french: Appeler une procédure/une fonction
The method for calling a procedure is the same, no matter whether it is a global procedure or a local procedure. Reminder: - In WLanguage, there is no distinction between the procedures and the functions. The syntaxes for declaring and using procedures also apply to functions.
Versions 16 and laterFor a multi-syntax procedure, the call to the proper syntax is resolved at run time. See Prototype overload for more details. New in version 16For a multi-syntax procedure, the call to the proper syntax is resolved at run time. See Prototype overload for more details. For a multi-syntax procedure, the call to the proper syntax is resolved at run time. See Prototype overload for more details.
Versions 21 and later New in version 21
// Call to the Find procedure that returns a boolean IF Find(Customer, CustNum, Number) THEN Info("Customer number found") ELSE Info("Customer number not found") END
Syntax
Calling a procedure that returns a parameter Hide the details
[<Returned Value> = ] <Procedure Name>([<Parameters>])
<Returned value>: Value returned by the procedure (optional), only if the procedure returns a result. Versions 18 and laterThe type of the return value of a procedure can be specified during its declaration. See Declaring a procedure for more details. New in version 18The type of the return value of a procedure can be specified during its declaration. See Declaring a procedure for more details. The type of the return value of a procedure can be specified during its declaration. See Declaring a procedure for more details. <Procedure name>: Name of the procedure to call. <Parameters>: Parameters passed to the procedure. Each parameter is separated by a comma.
Versions 20 and later New in version 20 Versions 19 and later
Calling a procedure that returns several parameters Hide the details
(<Value 1>, ..., <Value N>) = <Procedure Name>([<Parameters>])
<Value 1 to N>: Values returned by the procedure.The type of the return values of a procedure can be specified during its declaration. See Declaring a procedure for more details. <Procedure name>: Name of the procedure to call. <Parameters>: Parameters passed to the procedure. Each parameter is separated by a comma.
Versions 20 and later New in version 20 New in version 19
Calling a procedure that returns several parameters Hide the details
(<Value 1>, ..., <Value N>) = <Procedure Name>([<Parameters>])
<Value 1 to N>: Values returned by the procedure.The type of the return values of a procedure can be specified during its declaration. See Declaring a procedure for more details. <Procedure name>: Name of the procedure to call. <Parameters>: Parameters passed to the procedure. Each parameter is separated by a comma.
Versions 20 and later New in version 20
Calling a procedure that returns several parameters Hide the details
(<Value 1>, ..., <Value N>) = <Procedure Name>([<Parameters>])
<Value 1 to N>: Values returned by the procedure.The type of the return values of a procedure can be specified during its declaration. See Declaring a procedure for more details. <Procedure name>: Name of the procedure to call. <Parameters>: Parameters passed to the procedure. Each parameter is separated by a comma.
Versions 20 and later New in version 20 Remarks Special cases - To make your programs more readable, the PROCEDURE keyword can be replaced by the FUNCTION keyword.
- If the procedure expects no parameter, you can also use the following syntax:
[<Returned Value> = ] <Procedure Name>
- To run a procedure of an opened window, use ExecuteProcess. Example:
// Run the MyProc procedure found in WIN_MyWindow WinName is string = "WIN_MyWindow" ExecuteProcess(WinName + ".MyProc", trtProcedure)
Versions 20 and later New in version 20
This page is also available for…
|
|
|