Please enable JavaScript to view this site.

Process Designer

Navigation: PHP API > Work with Subtables

Add a row (insertSubtableRow)

Scroll Prev Top Next More

This function adds a new row to a subtable.

Parameter

Type

Description

$subtable

string

Subtable name

$row

int

Row ID. If a row already exists with this ID, all existing rows from this position on will be moved by one and the new row will be inserted at the set location.

$data

array

Associative array with the data for a new row (column name as key)

The function does not return a value.

Example:

$rowData = array('AMOUNT' => 100.0, 'PRICE' => 12.50, 'VAT' => 0.19);

$this->insertSubtableRow('INVOICEITEMS', 1, $rowData);

Please note: If you want to change subtable values within a form or step initialisation function, you have to call the save() method in addition to this function to write data into the sub-table during step processing.