I'm having trouble populating a custom multi-selec...
# suitescript
j
I'm having trouble populating a custom multi-select field, it throws the error invalid field value: containing the entity code \u00005 using suitescript 2.0 has anyone encountered it too? The script is a User Event script with the afterSubmit entry point
b
ignore the \u0005, its what netsuite uses internally as a delimiter for multiselect values. You should be checking that the select options you are trying to set are valid for the multiselect field.
j
The values that I'm selecting are being set on the multiselect field in the client side
here's a screenshot on how I did it in the front end using console
Here's my script, I can't seem to format it correctly so I uploaded it.
Here's the error I keep on encountering
b
id load the record in dynamic mode and use Field.getSelectOptions to make sure that the options that you are selecting are valid
j
I think you're on to something here, two values are not appearing on the getSelectOptions out of the three
The field is a multiselect that sources from the Entity. The one that appears is the Employee records, the other two are Partner records
b
probably want to check why its not an option. possibilities include inactive, classification restriction, permission restriction and probably others
j
You are correct! there is one inactive record and it was the one messing things up. Thanks @battk 😄