Skip to content

jx:updateCell

jx:updateCell replaces a single cell’s value with the result of an expression. Use it for summary cells, totals, timestamps, or any standalone computed value.

jx:updateCell(lastCell="A1" updater="totalAmount")
AttributeDescriptionRequired
lastCellThe cell to update (typically same as the command cell)Yes
updaterExpression whose result becomes the cell valueYes
data := map[string]any{
"employees": employees,
"totalAmount": 15750.50,
"reportDate": "2024-01-15",
}

Template cell A10 comment:

jx:updateCell(lastCell="A10" updater="totalAmount")

Cell A10 in the template can contain any placeholder text — it gets replaced with 15750.50.

Regular ${...} expressions work for most cases. jx:updateCell is useful when:

  • The cell is outside a loop and you want to set it from a specific context variable
  • You need the update to happen after other commands have run (it respects command ordering)

Browse all 19 runnable examples with input templates and filled outputs on the Examples page.

Auto-fit row heights for cells with wrapped text:

jx:autoRowHeight →