You need to sign in to do that
Don't have an account?

How to copy multi-select picklist value strings into Long Text Area field
I am trying to copy multi-select picklist values into a Long Text Area field. The issue I am running into is I'm able to copy over a single value, but when multiple values are selected it throws an error.

How can I split the String value so that the selection is copied into the Long Text Area with line breaks as follows:
Germany
Kentucky
Here's my code:
How can I split the String value so that the selection is copied into the Long Text Area with line breaks as follows:
Germany
Kentucky
Here's my code:
public class updateMultiSelectPicklistField { public static void updateMSelectPickField (ContentVersion[] ContentVersion1){ for(ContentVersion c: ContentVersion1){ c.Main_Offices__c = c.Office__c; } } }and trigger:
trigger updatefields on ContentVersion (before insert, before update) { ContentVersion[] ContentVersion1 = Trigger.new; updateMultiSelectPicklistField.updateMSelectPickField(ContentVersion1); }
Try below code
Mark it as "SOLVED" if your query is Answered
Regards,
Bhanu Mahesh
All Answers
Try below code
Mark it as "SOLVED" if your query is Answered
Regards,
Bhanu Mahesh