Via my myprocedure(appendthis) I want to set a tiddler field so its value concatenates its old value with the argument, to get the field value foo [[bar bar]] [[just appended]] (or possibly [[foo]] [[bar bar]] [[just appended]]). Order doesn’t matter.
But it is surprisingly difficult to get the brackets right. I get everything from no brackets to quadruples to… well, you get it. I’ve tried format:titlelist[] but nope.
(reflection: That is certainly too… I don’t know the appropriate word… maybe “special” or “intricate”… I’m a pretty darn experiened TW user and I get trapped in bits like these too often, so I am pretty sure it affects others too.. Is it a docs matter? Are we missing operators? Is there a more fundamental problem on the side of TW or myself?.. hmm…)
Both versions (action-listops and action-setfield) have the same limit: procedure parameter is considered as a single value to be appended to the existing list field.
If the parameter actually contains a list, not a single value, and the purpose is to merge this list with current field content, then it doesn’t work as is.
This. Code that edits lists can be tricky if you want to support spaces in the list items. A more complete documentation reading list, to help you understand what’s available for this kind of thing: