anyone getting MODULE_DOES_NOT_EXIST "Module does ...
# suitescript
s
anyone getting MODULE_DOES_NOT_EXIST "Module does not exist: /NLRecordScripting.scriptInit$sys.js" error while trying to set customform value on MR script?
let getInputData = () => {
let rec1 = record.create({type: record.Type.INVOICE, isDynamic: true});
rec1.setValue({fieldId: 'customform', value: 114});
}
if I set value to something that does not exist, it shows "You have entered an Invalid Field Value 158 for the following field: customform"
b
usually weirdness means you should be trying this on suitescript 2.0
you may also want to try using the customform default value if you really want to keep 2.1
s
while it shouldn't be an issue, try defining your
getInputData()
as a normal function statement rather than the longer form you show above.
also, dynamic mode seems more prone to wonkiness than standard mode in my experience.
s
setting the value through defaultValues did the trick. but I don't understand why it fails the other way.