Capitalize a String In Salesforce Apex
The Apex String class offered by Salesforce includes a bunch of useful functions to manipulate String, in case you would like the first letter of your String to be in title case you can use the capitalize function.
Code sample of String capitalize function:
String firstName = 'orleando';
System.debug(firstName.capitalize());
// The output will be 'Orleando'
Subscribe to our newsletter to be aware of the next snippet, article, or video to be released.