Banana.Document.Row

Deze documentatie is verouderd

De meest volledige en bijgewerkte documentatie is die van Banana Boekhouding Plus: Probeer het nu

In this article

Banana.Document.Row is the interface of a row.

Properties

isEmpty

Return true if the row is completly empty.

var isEmpty = tRow.isEmpty;

rowNr

Return the index of the row.

var rowNr = tRow.rowNr;

uniqueId

Return the unique id (an interger value) of the row.
Banana assign to every new row a unique id, this value is fix a will never change.

var uniqueId = tRow.uniqueId;

 

Methods

addMessage(msg [, columnName] [, idMsg])

Add the message msg to the document. The message is showed in the pane "Messages", and in a dialog if the application option "Show Messages" is turned on.

If idMsg is not empty, the help button calls an url with message's id (idMsg) as parameter.

If columnName is not empty, the message is connected to the column columnName. With a double click over message in the message pane, the cursor jump to the corresponding table, rowNr and columnName.

See also: Application.AddMessage, Table.AddMessageDocument.AddMessage.

var accountsTable = Banana.document.table("Accounts");        
var tRow = accountsTable.row(4);
tRow.addMessage("Message text");

toJSON([columnNames])

Return the row as JSON string. If the parameter columnNames is defined, only the columns in the array are included in the file.

// Return all the columns of the row
var json = tRow.toJSON();

// Return only the defined columns of the row
var json = tRow.toJSON(["Account", "Description", "Balance"]);

value(columnName)

Return the value in column columnName. If the column is not found or the object is invalid it return the value undefined.

var accountsTable = Banana.document.table("Accounts");        
var tRow = accountsTable.row(4);
tRow.value("Description");

 

Share this article: Twitter | Facebook | LinkedIn | Email