Depending on how the buttons are used and how many nested subforms are used, you only have to examine one row of the generated coding:var oWrapper = this.parent.parent;
If all four buttons should be nested in only one subform, which is absolutely sufficient, delete the one PARENT element and the coding will work directly.
The reason is that after you drag and drop the UI element into the layout, the generated coding expects the buttons to be nested into two subforms. Typically, one subform is sufficient and so one exterior subform can be deleted.
Starting with the four special buttons, the DATA row of the table FLIGHTS can be reached with the statement “this.parent.parent”.
The data row can be addressed via oData in the example above (oData is a kind of pointer to an object).
oData has a subobject or property instanceManager to manage further or existing instances. The manager's methods addInstance, removeInstance, and moveInstance can be used to manipulate the table and its rows.