deleteWhitespace() is used to remove spaces in a string in Salesforce.
Sample Code:
String str = 'Hello Hi';
system.debug(
str.deleteWhitespace()
); //HelloHi
deleteWhitespace() is used to remove spaces in a string in Salesforce.
Sample Code:
String str = 'Hello Hi';
system.debug(
str.deleteWhitespace()
); //HelloHi