RecordUi Class
Get picklist values by record type.
Apex methods in the RecordUi class can’t be used in packages that use push upgrades.
These methods are for RecordUi. All methods are static.
-
getPicklistValuesByRecordType(objectApiName, recordTypeId)
Get the values for all the picklist fields of a specific record type.
Get the values for all the picklist fields of a specific record type.
66.0
66.0
No
public static ConnectApi.PicklistValuesCollection getPicklistValuesByRecordType(String objectApiName, String recordTypeId)
- objectApiName
Type: String
API name of a User Interface API supported object.
- recordTypeId
Type: String
ID of a record type.
Type: ConnectApi.PicklistValuesCollection
This method is especially useful for getting dependent picklist values. For example, if an object has a tree of dependent picklists (Continents__c, Countries__c, Cities__c), use this method to get all the values for each picklist in one request.
This Apex method can’t be used in packages that use push upgrades.