ASSOCIATE-REACTIVE-DEVELOPER practice question 2 of 35

Considering the Function property in Client Actions, which of the following options is correct?

Full set: 262 questions
Answer options
A: Setting the Function property to Yes restricts the Action to have only one Output Parameter. Correct answer
B: Setting the Function property to No ensures the Action can only be used in the module where it is defined.
C: Setting the Function property to Yes is not possible, if the Action is exposed to other modules as Public.
D: Setting the Function property to No ensures the Action can only be used in Screen Expressions.
Correct Answer:
A. Setting the Function property to Yes restricts the Action to have only one Output Parameter.
Explanation

When the Function property of a Client Action is set to Yes, it is treated as a function that can be used directly within expressions. A core requirement for such functions in OutSystems is that they must return a single value. This is enforced by a design constraint that the Client Action must have exactly one Output Parameter, which serves as the function's return value. This ensures that the action can be evaluated predictably within an expression, for example, to assign a value to a variable or determine a widget's property.

Why Incorrect

B. An Action's reusability across modules is controlled by its Public property, not the Function property.
C. The Function and Public properties are independent. A Client Action can be both a Function (Function=Yes) and be exposed to other modules (Public=Yes).
D. This is incorrect. Actions with Function=Yes are used in expressions. Actions with Function=No are procedures called within action flows.

References

1. OutSystems Official Documentation, "Client Action": Under the "Properties" section for the Function property, it states: "If you set the Function property to Yes: The Client Action must have one, and only one, Output Parameter." This directly validates the correct answer.

2. OutSystems Official Documentation, "Reuse Logic": This document explains how to make logic elements, including Client Actions, reusable across modules by setting their Public property to Yes. This demonstrates that visibility is independent of the Function property, refuting options B and C.

3. OutSystems Guided Path, "Reactive Web Development - Logic": In the lesson on Client Actions and Functions, it is explained that actions configured as functions are designed to be used in expressions and must have a single output to return a value. This contrasts with standard actions (Function=No) which are used as steps in a logic flow. This refutes option D.

Scroll to Top