Nour Khaled
04/14/2025, 10:43 AMCeligo AI
04/14/2025, 10:44 AMAI generated answer (using internal Slack threads):The function
getCurrentSublistValue
is not available in the standard mode of SuiteScript. It is only available in dynamic mode. If you are using standard mode, you will need to use the getSublistValue
function instead.
In dynamic mode, you can use the getCurrentSublistValue
function to get the current value of a sublist field. However, to set a sublist value in dynamic mode, you need to use the selectLine
, setCurrentSublistValue
, and commitLine
functions in sequence.
Here is an example of how to use these functions in dynamic mode:
{
var myRecord = currentRecord.get();
myRecord.selectLine({
sublistId: 'sublist_2',
line: 0
});
myRecord.setCurrentSublistValue({
sublistId: 'sublist_2',
fieldId: 'fee_item',
value: 100,
ignoreFieldChange: true
});
myRecord.commitLine({
sublistId: 'sublist_2'
});
}
Remember to replace 'sublist_2' and 'fee_item' with your actual sublist ID and field ID.
******
Disclaimer:
This response was generated by an artificial intelligence assistant based on previous conversations from multiple Slack channels, and may contain inaccuracies or mistakes.
******Celigo AI
04/14/2025, 10:44 AMSlack thread 1: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.84340483
Slack thread 2: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.840338588
Slack thread 3: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.84030968
Celigo AI
04/14/2025, 10:44 AM