Icon Trim

Unit: WebCore

Available In: Client and Server Applications

function Trim(const Value: String): String

function Trim(const Value: String; TrimChar: Char): String

The Trim function returns the Value input parameter with both leading and trailing "space" characters removed. The first version of this function trims all leading and trailing characters that are less than or equal to the space (#32) character from the string. The second version of this function allows the developer to specify the character that should be trimmed from the Value parameter. The return value is a String value.

Examples

X := Trim('  Hello World  ');  // X is 'Hello World'
Image