An extension of the Var
variable of the PmData
object for invoking an event (action) when writing a value.
Format of saving the data extension as string
The contents of complete data extension (all configurators) can be saved as a single string. See Format of saving the data extension as string .
If calling the onItemBeforeWrite
event is enabled, then the event fires for this variable always closely before writing
or before the change of the variable value. Unconsidered enabling for all variables can cause unnecessary utilization of the processor. For example if the object includes 1000 variables and each one has calling enabled then by writing new values into all variables of the object can cause calling the onItemBeforeWrite
event 1000 times (each time with another pEvent.Item
parameter value). It is also better (if it is required to react to writing or the change of the variable) to enable the onItemAfterWrite
event instead of onItemBeforeWrite
. Enabling onItemBeforeWrite
is useful only if, for example, you need to test the written value and in a necessity to change it (to filter it). The pEvent.NewVal
parameter is in the onItemBeforeWrite
event defined for reading and writing
and thus it is possible in the event to enforce another value than the one that is really written.
If calling the onItemAfterWrite event is enabled, then the event fires for this variable always after writing or the change of the variable value. For enabling this event similar remarks are valid for the onItemBeforeWrite event. Enabling the onItemAfterWrite is useful for variables that change their value not too ofter and then is it suitable to enable calling 'after the change'.
Caution: The onItemBeforeWrite/onItemAfterWrite not fires if it isn't written into the variable directly, i.e. if the variable is bind to another value.