In our previous article, New to NetSuite | N/currentRecord Module Overview, we discussed the purpose and usage of the N/currentRecord module.
Continuing our deep dive into the N/currentRecord module, this article introduces the getColumn() method — a useful tool when working with sublists in client scripts.
What is getColumn()?
The getColumn(options) method is used to retrieve a column from a sublist on the current record. This allows your script to interact with metadata about a specific field within a sublist line — such as the field’s ID, type, or label.
Returns
- Type: currentRecord.Column or null
The method returns a Column object if the specified field exists on the sublist. Otherwise, it returns null.