openRecord
To jump to the related table and open a given record
This function closes your current form and opens the form of the given record together with the respective table. If you want, you can also specify the tab that should be opened.
To open the form of a record without leaving your current table, use popupRecord()
.
The function can be executed only on the client. Learn more about execution context.
Syntax
openRecord(nid)
openRecord(nid, string)
Return
void
Examples
openRecord(myRecord)
To jump to the related table and open a given record.
openRecord(first(select Customers))
Result: Opens the Customers table and the form of the first record.
openRecord(myRecord, tabName)
To jump to the related table and open a given tab of a given record.
openRecord(first(select Customers), "Company information")
Result: Opens the Customers table and the form of the first record with the Company information tab selected.
See also
openTable
, which opens a given table.
popupRecord
, which opens a given record in a pop-up form.