Activity › Forums › Salesforce® Discussions › What is the use of rightPad() method of String Class in apex ? Salesforce® Discussions What is the use of rightPad() method of String Class in apex ? Posted by Anuj on October 15, 2020 at 3:36 PM What is the use of rightPad() method of String Class in apex ? Kirandeep replied 5 years, 7 months ago 2 Members · 1 Reply 1 Reply Kirandeep Member October 15, 2020 at 3:39 PM It returns the current String padded with spaces on the right and of the specified length. Log In to reply. Public All Members My Connections Only Me PublicAll MembersMy ConnectionsOnly Me Public All Members My Connections Only Me