I want to add values in picklist, other then default values which are given at the time of creation of custom object field with data type Picklist. Suppose I created a custom object named: customObject__c then i created a new custom field with data type picklist and provided values while creation. Now I want to add more values in that but from the Apex code. Is there any way to add more values in picklist, without using MetaData API?


You can do this in Apex using this awesome wrapper class, but it still utilizes the Metadata API. There is a great example of updating a picklist value here


No, you'll need to use the metadata api.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.