is used to associate an identifier with a statement block. Then, the procedure can be called in a process.
A function is used to define a sub-program that performs several statements before returning a value to the calling program.
Difference between a procedure and a function:
- A procedure returns no result.
- A function returns a result.
In WLanguage, there is no distinction between the procedures and the functions. The procedures and the functions are managed in the same way. A procedure, like a function, may (or may not) return a result.
The procedures and the functions can have a fixed or variable number of parameters.
You have the ability to create overloaded procedures. For more details, see Prototype overload.