Tinderbox v9 Icon

Action Code

An action is an automatic way of setting a certain attribute to a certain value (with the exception of system read-only attributes which cannot be altered).

Here 'note' may be read to mean any note-like object (note, agent, adornment, etc.). The term 'rule' is just one form of applying an action and relates to the scope of its use. Actions can be invoked a number of ways:

*An ^action(some_code)^ export code allows inclusion of action code in an export template. The action code input some_code is executed when the template is evaluated. Attributes storing action events. View a full listing of attributes storing actions. 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. Making/deleting notes: See create(), createAgent() and delete(). Syntax: discussed under basic action code syntax. Note the point above re case-sensitivity. Originally, Tinderbox had 'actions' that notes applied to them elves or their children. These were written in 'Action Code' though at the time what is now 'Export Code' was generally used for internal macros (actions). In v4 and v5 this mix was clarified: Export Code moved to being for export only whilst all internal 'coding' was done using 'Action Code', i.e. the style of code used for writing actions. Action code is now the most likely, indeed only, form of automation users are likely to meet unless they use export features to pass information out of Tinderbox. Action Code is not a formal coding language (programmers, take note!), and being artisanal software has grown as needed: it has what it needs or its users has asked for. It may lack some features that those with a programming back ground might assume are 'standard'. Further discussion of use of actions: