function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Dmitry Chausov 8Dmitry Chausov 8 

How can I check "Enable thumbs up or down voting for article" option on the org

I need to get information about the option from the apex code. Tried to get PicklistEntry and check isActive flag:
Schema.DescribeFieldResult fieldResult = Vote.Type.getDescribe();
List<Schema.PicklistEntry> ple = fieldResult.getPicklistValues();
for(Schema.PicklistEntry f : ple){
    system.debug(f);
}
User-added image
All picklist options are active. 
 
Santosh Reddy MaddhuriSantosh Reddy Maddhuri
https://salesforce.stackexchange.com/questions/73379/add-knowledge-article-rating-entry-with-apex
Dmitry Chausov 8Dmitry Chausov 8
Thaks for your response.
But I need to get information about this setting from apex code (checked/unchecked): 
User-added image
Santosh Reddy MaddhuriSantosh Reddy Maddhuri
Hi Dmitry,

As far as my knowledge goes, you can find out about that setting only through Metada API or through wsdl file. You can learn about metadata api from this link

https://andyinthecloud.com/category/metadata-api/

Thanks!