RE: Set value on a dropdown field

Answered

When im trying to set values on regular fields everything works well but i cannot set a value on a dropdown field like record.setValue(id, value) always returns blank

Coder Beginner Asked on October 15, 2019 in How To's.

Share the code that fails.

on October 15, 2019.
Add Comment
2 Answers
Best answer

2 options:

  • If you know the Id of the dropdown record, then you can use that:

objRecord.setValue({ fieldId: ‘department’, value: 123});

  • If not, you can use setText

objRecord.setText({ fieldId: ‘department’, text: ‘Department 1’});

Rookie Answered on October 21, 2019.
Add Comment

Your Answer

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