RE: Error in sublist set value displaying custom body field

 

var dnote = result.getValue(result.columns[3]); // from custom body field

sublist.setSublistValue({
id : ‘colnotes’,
line : i,
value : dnote

// the browser gives me an error
//”type”:”error.SuiteScriptError”,”name”:”SSS_MISSING_REQD_ARGUMENT”,”message”:”Sublist.setSublistValue:
//Missing a required argument: options.value”,”stack”:[“createError(N/error)”,
//”onRequest(/SuiteScripts/WorkOrder_Script.js:204)”,”createError(N/error)”],”cause”:{“name”:”SSS_MISSING_REQD_ARGUMENT”,
//”message”:”Sublist.setSublistValue: Missing a required argument: options.value”},”id”:””,”notifyOff”:false,”userFacing”:true}
});

ian_val Rookie Asked on August 25, 2021 in SuiteScript.
Add Comment
1 Answers

Please look into sublist API:  I don’t seem to find a sublist ID, field ID mentioned accurately.


objRecord.setSublistValue({
    sublistId: 'item',
    fieldId: 'item',
    line: 3,
    value: true
});
Beginner Answered on August 25, 2021.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.