Question
How can I block changes in a table, including calculated values? There is a certain calculation. When it is ready, it is fixed. The parameter block:true in the table formatting blocks manual input and changes. But fields with codes that depend on external sources (e.g., exchange rates, etc.) continue to recalculate.
Answer
Globally, there are 2 approaches.
"Code only on addition"
recalculate
with the field
parameter, specifying the fields that need to be updated. When passing the field, the code will be executed again and get fresh values.Block when setting some parameter. Then the code in the field will look like this:
=: if(condition: #param = true; then: $#onfv; else: $calc)
calc: "some code for calculations here"
In this case, if the control parameter is true, we take the previous value of this field; if not, we calculate a new value.