Wednesday, 20 July 2016

Fetch RecordType Id without Query Salesforce

//get Case's Internal record type Id
Id recordTypeId  = Schema.SObjectType.Case.getRecordTypeInfosByName().get('Internal').getRecordTypeId();
  • Here I am fetching Internal Record Type of Case Object
  • Internal is label of Record Type not Developer Name

No comments:

Post a Comment