Expand my Community achievements bar.

Enhance your AEM Assets & Boost Your Development: [AEM Gems | June 19, 2024] Improving the Developer Experience with New APIs and Events

for-loop over dynamic table to hide buttons


Level 1



I have a form with a dynamic table. You can add or remove rows via buttons.

Before sending the form I want to execute a for-loop over the rows to hide these buttons.


The message box shows the right number of rows:

xfa.host.messageBox("Number of rows: " + Formular1.receipt.table.dataRow.instanceManager.count);


But unfortunately I don't know the commands for the loop. Any help really appreciated.


Thanks and regards,






1 Reply


Level 1

Solved it right now - after lunch 


The commands are:


var numberRows = Formular1.receipt.table._dataRow.count;

for (var i = 0; i < numberRows; i++)
{ resolveNode("Formular1.receipt.table.dataRow[" + i + "]").rowPlusMinus.btnPlus.presence = "invisible";
resolveNode("Formular1.receipt.table.dataRow[" + i + "]").rowPlusMinus.btnMinus.presence = "invisible";