[Overview][Resource strings][Constants][Types][Procedures and functions][Index] Reference for unit 'strutils' (#rtl)

RemovePadChars

Remove any trailing or leading characters in a set from a string

Declaration

Source position: strutils.pp line 205

procedure RemovePadChars(

  var S: AnsiString;

  const CSet: TSysCharSet

);

Description

RemovePadChars removes any leading trailing characters from S that appear in the set CSet, i.e. it starts with the last character and works its way to the start of the string, and it stops removing characters as soon as a character not in CSet is encountered. Then the same procedure is repeated starting from the beginning of the string. This is similar in behaviour to Trim which used whitespace as the set.

Errors

None.

See also

Trim

  

Trim whitespace from the ends of a string.

RemoveLeadingChars

  

Remove any leading characters in a set from a string

RemoveTrailingChars

  

Remove any trailing characters in a set from a string

TrimSet

  

Remove any leading or trailing characters in a set from a string and returns the result

TrimLeftSet

  

Remove any leading characters in a set from a string and returns the result

TrimRightSet

  

Remove any trailing characters in a set from a string and returns the result


Documentation generated on: Nov 14 2015