An action is an automatic way of setting a certain attribute to a certain value (with the exception of system read-only attributes which can't be altered). In the context of this section, Rules should regarded as synonymous as they differ only in the scope of action. Similarly, here 'note' may be read to mean any note-like object (note, agent, adornment, etc.).
Case sensitivity: Action code operators are always case-sensitive (unlike export codes).
Agents can have actions. An agent performs its action on aliases of all the notes it finds that match its agent query.
Notes can have actions. A note performs its action, once - via $OnAdd, on all its children — but not on the children's children, i.e. descendants. A rule ($Rule) is a special form of note action whose effect is applied only to the note and not any children. To effect both the note and children, the same code can be added as both and action and a rule.
Making/deleting notes: action code can not create new notes nor delete existing ones.
Syntax: discussed under basic action code syntax. Note the point above re case-sensitivity.
- Basic action code syntax
- Operators
- Compound Actions
- Conditional Actions (if clauses)
- Conditional statements using multiple arguments
- Expressions in paths
- Delaying code execution in Prototypes
- Stand-alone expressions
- Left side expressions
- The 'dot' operators
- Chaining 'dot' functions
- Stamps
- Setting an attribute to (no value)
- Short Boolean form
- Setting an attribute to re-enable inheritance
- Self-Cancelling Rules & Actions
- Using long sections of code
- Using .each() for loops
- Concatenation versus addition
- Parentheses as a guide to code execution
- Updates and cascading actions
- Optimising code for performance
- Checking and setting Time correctly in Date data
- Debugging user Action code
- Getting section number via Action code
- Referencing root-level items
- Pre-populating key attribute pop-up lists
- Using designator values as note titles
- Invoke command line scripts via back-tick (DEPRECATED)
- Using Export codes in Actions (DEPRECATED)