Before packs:
In my table, I have a button that pushes other buttons in the same row (runActions()
). Each child button in the row has some complicated formulas inside that will basically AddRow()
using data from thisRow. Moreover, each child button’s AddRow() formulas are nearly identical, so if I modify one button, I then have to tediously modify the others. (I attempted to consolidate them into 1 button using withName(), but it became even more complicated.)
So now, I am attempting to consolidate all of this logic into one super button, powered by a Coda Pack formula.
After packs:
In my pack formula, I set isAction: true
, and Coda allows me to use the custom formula in my parent button! In the button formula editor, I can associate columns with formula parameters. However, inside the execute
property of my pack.AddFormula
, I cannot find a way to use AddRow() based on the parameter data.
Although, asking a formula to addRow() would probably require it to know the structure of the document. Maybe this could be achieved by prompting the user to create or associate the required tables/columns, but this sounds messy.